MATLAB: What is causing this, ‘Function ‘subsindex’ is not defined for values of class ‘cell’.’

subsindex

It worked once before and now it will not give the time of day. Can anyone with this issue?
last = {'Smith';'Jones';'Webb';'Anderson'};
first = {'Fred';'Kathy';'Milton';'Johnn'};
age = [6;22;92;45];
height = [47;66;62;72];
weight = [82;140;110;190];
table(last,first,age,height,weight)
This is the error
Function 'subsindex' is not defined for values of class 'cell'.

Best Answer

You have redefined the term "table" as a variable. See:
which table -all
This so called shadowing causes troubles frequently. The solution is easy: Avoid using names of built-in functions as variables. In your case:
tableback = table;
clear('table');
Then your code runs successfully.