Answered
Transformation of attached C++ code to MATLAB code.
Are you required to convert this code or would being able to call it from within MATLAB be sufficient for your needs? If the lat...

4 years ago | 0

Answered
If I have a matrix, how can I find the minimum5 values in it?
Use the mink function.

4 years ago | 0

Answered
NEWPR and NEWFF .
They are extremely old functions in Deep Learning Toolbox (when they were marked as obsolete in release R2010b, the toolbox was ...

4 years ago | 0

Answered
Randomness is lost in parfor loop on GPU?
What I'm doing is to copy this code and change the value of the seed. For example, the "my_code_seed1.m" uses "seed = 1", and "m...

4 years ago | 0

Answered
CVE-2022-23307 vulnerability
Please contact Technical Support with this question to receive an official answer.

4 years ago | 0

Answered
Making a moving average filter without looking in to the future. So forecasting the data, how do you do it?
Use the movmean function with the M = movmean(A, [kb kf]) syntax given on its documentation page. Choose kf = 0 to include 0 ele...

4 years ago | 0

Answered
Highlighting of function call in editor
See the first item in the table in the Editor/Debugger Display Preferences section on this documentation page.

4 years ago | 0

Answered
Nonscalar arrays of function handles are not allowed; use cell arrays instead.
You need to evaluate the function handles in your fsolve call. Alternately you could skip converting the symbolic expressions in...

4 years ago | 0

| accepted

Answered
How to find the source code of the guide examples?
If you have Stateflow installed on your machine or if you have a license to access Stateflow in Simulink Online, open the exampl...

4 years ago | 0

Answered
Evaluate the surface area of the solid of revolution generated by revolving the graph of (𝑥) around the 𝑥-axis between −2𝜋 and 2𝜋.
Neither diff nor * are defined for function handles. try diff(@sin) catch ME fprintf("The error was: %s\n", ME.messa...

4 years ago | 0

Answered
Unrecognized function (iforest) even though the toolbox is installed
According to its documentation page the iforest function was "Introduced in R2021b". If you're using an older release of Statist...

4 years ago | 1

| accepted

Answered
Toolboxes installed and licensed, but not in use
I'm not entirely certain what your concern is. Are you wondering why license inuse doesn't list all of the products that appear ...

4 years ago | 0

| accepted

Answered
How do I convert a vector into an Nx1 cell array of varying-length vectors?
Use mat2cell (with a transpose call if you need an N-by-1 instead of a 1-by-N.) V = [1 2 3 4 5 6 7 8 9 10] R = mat2cell(V, 1, ...

4 years ago | 0

Answered
Get old Find & Replace window back?
Open the Preferences using the button in the Environment section on the Home tab of the Toolstrip. Under MATLAB, expand the Key...

4 years ago | 1

| accepted

Answered
How would I prevent access to classes that shouldn't be publicly available in my toolkit?
The way I'd probably do this is to make the class constructor for the "private" classes have Access='protected' (so only accessi...

4 years ago | 0

Answered
Creating few columns of the Vandermonde matrix without using vander
You could do this pretty easily if you know the powers to which you want to raise the data used to create the Vandermonde matrix...

4 years ago | 0

Answered
Histogram plot by equal time intervals
Rather than specifying the number of bins you could specify the bin edges explicitly. minutesPerDay = minutes(days(1)); T = da...

4 years ago | 0

Answered
Add NaN values in a timetable based on missing datetimes
Here's some sample data. MeasurementTime = datetime({'2015-12-18 08:03:05'; ... '2015-12-18 10:03:...

4 years ago | 0

| accepted

Answered
Too many inputs to CFIT/SUBSREF.error when using a for loop
As long as there is a variable named fit it takes precedence over the function named fit, preventing you from calling the functi...

4 years ago | 0

Answered
Access variables in parallel computing
The functionality in MATLAB to perform background processing may be of use to you.

4 years ago | 0

Answered
Changing the variable used in a loop
Can you iterate over numbered variables like tube_L1, tube_L2, tube_L3, etc? Yes. Should you do this? The general consensus is ...

4 years ago | 0

Answered
divide text into smaller blocks text by . or enter
S = "Today is a good day. Mom cooks breakfast for us." + newline + ... "But I find out only my sister is served." T = split(S,...

4 years ago | 0

| accepted

Answered
How can i write infinite symble in matlab using keyboard shortcut
It depends. What's the context in which you want to use this symbol? If you want to use it as the name of a variable in your co...

4 years ago | 0

Answered
randsample not working in matlab 2022a release , is there any alternative?
The randsample function is part of Statistics and Machine Learning Toolbox. Check the output of the ver function to determine if...

4 years ago | 1

| accepted

Answered
How to extract an element from a ''vector'' of function handle
If you've already created your f function you could do this using one helper function. I vectorized your f function. f = @(x1,x...

4 years ago | 0

| accepted

Answered
Append apostrophe as a text in a function for a searching tool
Instead of calling mat2str repeatedly I'd use the + operator for string arrays to build up the filename. x = 1; y = 2; z = 3;...

4 years ago | 0

Answered
Anonymous function arguments and parameters extrction
As written, as long as you know how long either one of the inputs was, yes. P = @(x, y) [x, y]; x1 = 1:5; y1 = 6:10; z = P(x...

4 years ago | 0

Answered
finding the determinant of a non function without using built-in functions
Your function does not satisfy your stated requirements. All of input, size, ne (the function form of the ~= operator), and disp...

4 years ago | 0

Answered
Unable to resolve the name simulink.compiler.genapp('modelName')
Check the output of ver to determine if you have Simulink Compiler installed. This is the product that contains the simulink.com...

4 years ago | 0

| accepted

Answered
I can't run the software because my username doesn't match the username in the license file. How can I solve this problem?
See if any of the scenarios listed in this Answer apply to your situation and apply the suggestion for that scenario if it does....

4 years ago | 0

Load more