%% Specify y-Axis Tick Labels for Specific Axes
% Starting in R2019b, you can display a tiling of plots using the tiledlayout and nexttile functions. Call the tiledlayout function to create a 2-by-1 tiled chart layout. Call the nexttile function to create the axes objects ax1 and ax2. Create two plots of random data. Set the y-axis tick values and labels for the second plot by passing ax2 as the first input argument to the yticks and yticklabels functions.

tiledlayout(2,1)
ax1 = nexttile;
plot(rand(3))

ax2 = nexttile;
plot(rand(3))
yticks(ax2,[0 .25 .5 .75 1])
yticklabels(ax2,{'y = 0','1/4','1/2','3/4','y = 1'})

% Copyright 2019 The MathWorks, Inc.