Hello,
Fairly new to matlab, and I am having trouble with the table functionality. I am reading two .csv files into a table and I want to cycle through a list of selected variables, compare the data corresponding to that variable in each table, output a plot, then move on to the next.
My issue is that I can't find a good way to index through each variable without brute force typing out every vame.
b_table = readtable('base.csv');
b_table(2,:) = [];
f_table = readtable('test.csv');
f_table(2,:) = [];
x_base = (b_table.A);
x_baseunits = x_base(1);
x_base(1) = [];
base_array =cellfun(@str2num, x_base);
Ideally I just want to do a for or while loop in a function to spit out all the info for variables but the main issue is how to cycle through the variables.
I know this is incorrect, but something like
myVars = { A , B, C, D};
b_table.A(:, myVars);
Any help would be greatly appreciated!!