Means, Standard Deviation and Broken line plot
古いコメントを表示
I wish to calculate the mean/standard deviation of a single column in the excel file that will be created at the end of my task, as well as create a broken line plot (instead of the stairs you can see in the code). I'm currently using PsyToolBox.
Here is the little i've figured out so far:
T = readtable('Test.xlsx')
summary(T);
Avg = mean(T,1);
figure
stairs(T.RT)
grid
5 件のコメント
dpb
2020 年 12 月 9 日
No idea what the PsyToolBox contains that matters and not sure what you mean by a "broken line" plot?
Hugo Laflamme
2020 年 12 月 9 日
dpb
2020 年 12 月 9 日
That's what you'll get by
plot(T.RT,'-.',markersize',10)
See the doc for plot function for details of line style, etc., ...
Hugo Laflamme
2020 年 12 月 9 日
dpb
2020 年 12 月 10 日
grpstats is probably most convenient way to return a plethora of statistics -- but it requires a grouping variable so to do the whold dataset will need to introduce a constant to serve the purpose
stats=grpstats(T,ones(height(T),1));
If there are nonnumeric variables in the table, then will have to specify whch are numeric with the optional 'DataVars' named parameter. You select the statistics desired with a cell array to specify multiple types of summary statistics.
See the doc for details, examples of use. Requires the Statistics Toolbox
回答 (0 件)
カテゴリ
ヘルプ センター および File Exchange で Descriptive Statistics についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!