-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adds remove methods for all API classes #347
Conversation
API/projectClass/tableUtilities.m
Outdated
|
||
obj.varTable(row, :) = []; | ||
|
||
indices = sort(indices, 'descend'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since the indices are sorted here, the sort on line 60 is not needed. Also the for loop below is not needed since indices is sorted.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If the input is a cell array of multiple row names, the resulting indices array will not be sorted, so it is needed here. There's also no guarantee that a list of rows provided is valid so I think the for loop is still needed too.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ahh, sorry. Misread here. I'll take out the sort on line 60 too.
end | ||
end | ||
|
||
obj.varTable(indices, :) = []; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This line should work with unsorted indices so maybe the sort can be removed
Closes #340