What do these next 2 lines show in your command window?
whos t
which -all plot
built-in (/MATLAB/toolbox/matlab/graph2d/plot)
/MATLAB/toolbox/matlab/graphics/math/@digraph/plot.m % digraph method
/MATLAB/toolbox/matlab/graphics/math/@graph/plot.m % graph method
/MATLAB/toolbox/matlab/timeseries/@timeseries/plot.m % timeseries method
/MATLAB/toolbox/matlab/graphics/math/@polyshape/plot.m % polyshape method
/MATLAB/toolbox/matlab/graphics/math/@alphaShape/plot.m % alphaShape method
/MATLAB/toolbox/matlab/bigdata/@tall/plot.m % tall method
/MATLAB/toolbox/bioinfo/bioinfo/@phytree/plot.m % phytree method
/MATLAB/toolbox/bioinfo/microarray/@HeatMap/plot.m % HeatMap method
/MATLAB/toolbox/bioinfo/microarray/@clustergram/plot.m % clustergram method
/MATLAB/toolbox/curvefit/curvefit/@cfit/plot.m % cfit method
/MATLAB/toolbox/curvefit/curvefit/@sfit/plot.m % sfit method
/MATLAB/toolbox/econ/econ/@conjugateblm/plot.m % conjugateblm method
/MATLAB/toolbox/econ/econ/@diffuseblm/plot.m % diffuseblm method
/MATLAB/toolbox/econ/econ/@mixconjugateblm/plot.m % mixconjugateblm method
/MATLAB/toolbox/econ/econ/@lassoblm/plot.m % lassoblm method
/MATLAB/toolbox/econ/econ/@mixsemiconjugateblm/plot.m % mixsemiconjugateblm method
/MATLAB/toolbox/econ/econ/@empiricalblm/plot.m % empiricalblm method
/MATLAB/toolbox/econ/econ/@blm/plot.m % blm method
/MATLAB/toolbox/econ/econ/@customblm/plot.m % customblm method
/MATLAB/toolbox/econ/econ/@semiconjugateblm/plot.m % semiconjugateblm method
/MATLAB/toolbox/ident/ident/@iddata/plot.m % iddata method
/MATLAB/toolbox/ident/nlident/@idnlarx/plot.m % idnlarx method
/MATLAB/toolbox/ident/nlident/@idnlhw/plot.m % idnlhw method
/MATLAB/toolbox/mpc/mpc/@mpc/plot.m % mpc method
/MATLAB/toolbox/robust/rctobsolete/robust/@frd/plot.m % frd method
/MATLAB/toolbox/robust/robust/@umargin/plot.m % umargin method
/MATLAB/toolbox/shared/channel/rfprop/@propagationData/plot.m % propagationData method
/MATLAB/toolbox/shared/drivingscenario/@drivingScenario/plot.m % drivingScenario method
/MATLAB/toolbox/signal/signal/@dspdata/plot.m % dspdata method
/MATLAB/toolbox/stats/bayesoptim/@BayesianOptimization/plot.m % BayesianOptimization method
/MATLAB/toolbox/stats/classreg/@LinearModel/plot.m % LinearModel method
/MATLAB/toolbox/wavelet/wavelet/@dtree/plot.m % dtree method
/MATLAB/toolbox/wavelet/wavelet/@wdectree/plot.m % wdectree method
/MATLAB/toolbox/wavelet/wavelet/@ntree/plot.m % ntree method
x = [1:5000]';
y = sin(2 * pi * x / 1000);
t = table(x, y)
t = 5000×2 table
x y
__ _________
1 0.0062831
2 0.012566
3 0.018848
4 0.02513
5 0.031411
6 0.03769
7 0.043968
8 0.050244
9 0.056519
10 0.062791
11 0.06906
12 0.075327
13 0.081591
14 0.087851
15 0.094108
16 0.10036
plot(t.x, t.y); % See No error if you do it right.