Error: Undefined operator './' for input arguments of type 'table'
Mostrar comentarios más antiguos
I have a +330,000,000 row .txt file (attached a 1000 row sample .txt) that I am attempting to perform a linear regression on using the following script:
Clm = ('sample.txt');
t = readtable(Clm, 'Delimiter','comma');
>> x = t(:,2);
>> y = t(:,4);
format long
b = x./y
yCalc1 = b*x;
scatter(x,y)
hold on
plot(x,yCalc1)
xlabel('Pressure')
ylabel('Depth')
title('Pressure vs Depth')
grid on
I get the following return error:
Undefined operator './' for input arguments of type 'table'.
I have tried
b = divide(x,y)
and
b = x/y
neither alternative works.
I also get the same error for the multiplication on:
yCalc1 = b*x;
1 comentario
per isakson
el 29 de Dic. de 2018
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre Tables en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!