Answered
Event in ode45 doesn't work
You've pasted your code all out of order, but once I ordered it correctly, it runs as expected. EDIT: I did change the first li...

26 days ago | 0

Answered
Overlapping line plots in one graph for numerous cycles
There are likely many different ways to do this. My first instinct is to use findgroups and splitapply. rawdata = readtable('Ne...

27 days ago | 1

| accepted

Answered
Why do I receive Error loading .mlapp?
Try looking in your MATLAB Drive deleted files folder (https://drive.matlab.com/trash/). If there is a backup file there, restor...

27 days ago | 0

| accepted

Answered
I keep getting this error, "Not enough input arguments" for my fit function. How to resolve this?
You may need to share your data. When I run your code with some made up data, I do not get an error. Please share the complete ...

27 days ago | 0

Answered
Wanting to + inside an if statement once a variable reaches 1, not sure how to do it?
The reason is that r is a vector. The conditional statement of an if statement is not elementwise, meaning that it only executes...

27 days ago | 0

Answered
Plotting four positive quadrants
What is plotted vs what is used as a label can be different. I suggest plotting the negative of KPI(2) and Parameter2, but label...

27 days ago | 0

Answered
Not enough input arguments in addon function for arduino UNO.
I can't test, but I suspect you need to you the following syntax shield = addon(a,'Adafruit\MotorshieldV2',Name,Value) So the ...

28 days ago | 0

Answered
I am writing a code that allows a user to enter their name, and then check if the name starts with A,B or C and do someting. I am getting an error, please check my code below
Use the optional 2nd input to input to indicate the input is a string. txt = input(prompt,"s") name = input('enter your name :...

1 month ago | 0

Answered
In a table I have a column made of strings which are often repeated (sort of categories), I would like to substitute them with numbers which represents the categories
I would first consider keeping it a categorical. You have not explained why you need it to be a numeric value. However, if you n...

1 month ago | 0

| accepted

Answered
Split the data into 70% training and 30% test in classification learner?
What version of MATLAB are you using? In R2022a, there is an option to set aside a percentage of the data to use as test data. ...

1 month ago | 1

| accepted

Answered
why do I get error for Undefining function sdpvar and how can I solve it?
You have not installed YALMIP Toolbox. Once you do, you will have access to sdpvar. This is not a MathWorks supplied toolbox, s...

1 month ago | 0

Answered
App Error 'value' must be double scalar within the range of 'limits' Can't really find a way to fix
Another option is to call the other callback functions at the start of the Calculate callback to ensure app.MOD and app.EDMG hav...

1 month ago | 0

Answered
How to remove horizontal spacing between subplots?
Consider using tiledlayout instead of subplot. You can then use the TileSpacing input to adjust the spacing. t = tiledlayout(2,...

1 month ago | 0

| accepted

Answered
How create moving plot in MATLAB grader (in moodle)
You cannot create an animation in MATLAB Grader. At least not one that you will be able to see. This is because your code actual...

1 month ago | 0

| accepted

Answered
find out dependent variables from an expression
syms x y=x^2+2; symvar(y)

1 month ago | 0

Answered
How to fix the following error while writing matlab code for definite integral
It would appear the first input to int is not a symbolic expression. See here. Look at these examples for how to use int.

1 month ago | 0

Answered
Unable to update MATLAB 2016b to 'update 7'
Based on the message, it appears you need to contact support. You can do so here: https://www.mathworks.com/support/contact_us....

1 month ago | 0

Answered
How to find specific text in a string?
I'm sure there is a regexp way to do this, but I find it easier to use pattern with its supporting functions. Here's how I would...

1 month ago | 0

| accepted

Answered
Error using plot Vectors must be the same length. ı have a plot error .İs there any advicethis problem
There are not enough details to say why your vectors are not the same length, but your X and Y vectors are not the same length i...

1 month ago | 0

Answered
Removed Support for Certain Functions in MATLAB Grader?
The error I get when running a similar example in Grader is Error using matlab.internal.lang.capability.Capability.require Th...

1 month ago | 1

| accepted

Answered
Same values's aswer in MATLAB Grader but identified as a mistake.
How have you set up your assessment test? Are you using the Variable Equals Reference Solution test or a MATLAB Code test type? ...

2 months ago | 0

Answered
MATLAB grader in moodel.
Limiting the number of attempts is done via custom parameters. See my comment in this answer: https://www.mathworks.com/matlabc...

2 months ago | 0

Answered
Index in position 2 exceeds array bounds. Index must not exceed 2
The error is likely from this indexing operation: XTest(:,i-1) My guess is that XTest only has 2 columns, but your indexing in ...

2 months ago | 0

Answered
Operator '-' is not supported for operands of type 'timetable'.
A timetable holds several variables of different data types. You must specify which variable in your timetable you want to subtr...

2 months ago | 0

| accepted

Answered
Plotting datapoints with their time distance on x-axis
It's hard to say for certain, since you have not shown how the times correspond to your step plot, but here's some simple code t...

2 months ago | 0

| accepted

Answered
what is helperRangeDoppler ?
In the top right of the page, click the Copy Command button. Then run that command in your command window. openExample('phased...

2 months ago | 1

Answered
Can someone help me explain this code?
Consider going through MATLAB Onramp. You'll also find the help documentation quite detailed, with accompanying examples. colo...

2 months ago | 0

Answered
I need to buy 25 Licenses of MATLAB Student Suite License, so shall i repeat buying price 25 times ??
I would suggest contacting sales, not support. https://www.mathworks.com/company/aboutus/contact_us/contact_sales.html

2 months ago | 1

Answered
Why the assessment shows the keyword not presented however it is in the code in the MATLAB grader?
The reason is that descend is not a function or keyword. It is an input argument to the sort function. exist('descend') iskeyw...

2 months ago | 1

Answered
Cannot simplify a result
Symbolic results are exact. If you want a decimal approximation, convert the symbolic value to a double. syms rho x L E w t csi...

2 months ago | 1

| accepted

Load more