Answered
infinity video frames acquired
Assuming _vid_ is a VideoReader then: vid.hasFrame

8 years ago | 0

Answered
How to export the workspace variable INFORMATION, such as Name, Value, Bytes, Class.
S = whos; T = cell2table(struct2cell(S)','VariableNames', matlab.lang.makeValidName(fieldnames(S))); writetable(T,'whatever....

8 years ago | 1

| accepted

Answered
X random integers between 1 and 25
randperm(25,x)

8 years ago | 0

Answered
imrotate in Matlab App Desinger
You're calling imshow on the uiaxes not the image. I would manage this like this: app.UIAxes = uiaxes; % You won't need th...

8 years ago | 0

Answered
How do I include my simulink model in a live script
*New* I went ahead and wrote a simple function that does this for you. It requires Simulink Report Generator and R2017b. I ...

8 years ago | 2

| accepted

Answered
Matlab Report Generator to be used on Standalone application
My guess it that it's failing to find the template. Two possible reasons: # You didn't include the template in the Deploymen...

8 years ago | 1

| accepted

Answered
How do I expose the code in a function .m file within Live Editor
Use |dbtype| This also allows you to specify which lines in a function to show (skip error checking, etc).

8 years ago | 0

Answered
Matlab .fig files under Git version control
You can see some of the changes by comparing revisions in MATLAB Git from within the current folder browser. It's limited in wh...

8 years ago | 0

Answered
I'm trying to call patch without permanently changing my X axis from a datetime array.
Use |fill| instead of patch. % Create data & plot x = datetime(2017,1,1) + caldays(1:31); y = rand(1,31); plt = plot(x, ...

8 years ago | 2

Answered
Is it possibe to have a custom image as a control in Matlab App Designer?
You could put the image in and then put a slider underneath that rotates the image as the slider moves. You move the slider to ...

8 years ago | 1

Answered
How to print multiple figures to same PDF page?
This is easily doable with MATLAB Report Generator though it could be overkill. Example requires 17b but could be done using ...

8 years ago | 2

Answered
Simple question regarding bar plot with categorical data
x = categorical(["bananas" "apples" "cherries"]); x = reordercats(x,{'bananas' 'apples' 'cherries'}); y = [14,12,7]; bar(...

8 years ago | 5

| accepted

Answered
Fast low latency live data transfer
Have you considered using Instrument Control Toolbox which has native UDP capabilities? <https://www.mathworks.com/help/relea...

8 years ago | 0

Answered
I am getting a syntax error with +
t=[0,1,2,3,4,5,6,7,8]; y=((20.*t.^(2/3))/(t+1))-(((t+1).^2)/(exp((.3.*t)+5)))+(2./(t+1)) + is implied to be an elementwis...

8 years ago | 2

| accepted

Answered
problem with varbacktest/runtests in Matlab_R20017a
More than likely you're shadowing a function that runtests calls. Try turning on |dbstop if error| so the debugger will stop ...

8 years ago | 0

| accepted

Answered
Testing framework: Only test specific parameter combinations
You can use the |TestSuite.selectIf| with |HasParameter| and boolean logic with multiple HasParameters to remove them. <https...

8 years ago | 0

| accepted

Answered
How do I bin a 96x256x256 to 96x128x128?
Look at griddedInterpolant to downsample with interpolation to the size you want.

8 years ago | 0

Answered
Hi! can any one help me how to password protect a matlab file or the folder in which the file is stored so that no one can delete it.
Why not use git source control? Then they can delete it all they want and all you have to do is pull or clone again but if they...

8 years ago | 0

Answered
Write Objective function with known linear regression model
This is kind of the old way of doing it. I would just use the |predict| method of the object to make the prediction. f = @...

8 years ago | 1

Answered
Delete rows when a value repeated less than 5 times
m = [1 201 1 2 202 1 3 203 1 4 204 1 5 205 1 6 206 1 7 207 2 8 208 2 9 209 2 10 210 2 1...

8 years ago | 2

| accepted

Answered
Converting a string Array into a Char array
Use |datetime| and then change the Format to that which you desire. dt = datetime('22:39:04.502727','InputFormat','HH:mm:ss...

8 years ago | 0

Answered
How to locate errors reported by the MATLAB compiler
Turn on stop on errors: dbstop if error Now the debugger should stop when the error occurs. If it does not, try |dbstop...

8 years ago | 0

Answered
Links in method help / documentation
methods function foo % <a href="matlab:disp('Hello World')">Hello!</a> end end

8 years ago | 1

| accepted

Answered
Optimization toolbox and algebraic modelling language
The R2017b prerelease is available for customers current on maintenance. You might like it.

8 years ago | 0

Answered
How to convert hourly data to monthly average?
tt = table2timetable(wavetable); retime(tt,'monthly','mean') Time tables make this type of work super straightforward.

8 years ago | 0

| accepted

Answered
Splitting a table to 2
If you're looking to split your data into a training and testing set, then it might pay to look at |cvpartition| as well, it pro...

8 years ago | 0

Answered
I need to update an MS Word document with new Matlab Figures and tables. The document does have text within it. Is there a way to open the MS Word document and replace the applicable Figures and tables?
With the MATLAB Report Generator DOM API in releases >= R2014b this is easily doable. <https://www.mathworks.com/help/release...

8 years ago | 0

Answered
Use tfest within parallel loop
assign the output back to a cell array estSys{i} = tfest(...)

8 years ago | 0

Answered
From a pdf to a histogram.
Look at the _'Normalization'_ property of |histcounts|.

8 years ago | 0

Answered
I'm using the histogram function, I would like to reduce the frequency of the y-axis
ax = gca; ax.YScale = 'log' Set the y axis to log scale.

8 years ago | 0

| accepted

Load more