%% Transform Laser Scans
% Create a lidarScan object. Specify the ranges and angles as vectors.

refRanges = 5*ones(1,300);
refAngles = linspace(-pi/2,pi/2,300);
refScan = lidarScan(refRanges,refAngles);

% Translate the laser scan by an [x y] offset of (0.5,0.2).

transformedScan = transformScan(refScan,[0.5 0.2 0]);

% Rotate the laser scan by 20 degrees.

rotateScan = transformScan(refScan,[0,0,deg2rad(20)]);

% Copyright 2019 The MathWorks, Inc.