Respondida
Adding zeros to a column vector to match a larger column vector
If you're using release R2023b or later, you could use the paddata function. Let's create some sample data: % I have x where th...

más de 2 años hace | 0

Respondida
Creating a VAT Calculator in MATLAB
Is there a specific reason you're trying to create the app as a script file yourself? I'd consider using App Designer. If you ha...

más de 2 años hace | 0

Respondida
For loop problem for matrix
There are two values which are changing VGPL_xi and values that depend on K and VGPL_xi. Ah. So you're trying to figure out how...

más de 2 años hace | 0

Respondida
How to add zeros to the end of an array
If you're using release R2023b or later, you could use paddata or resize to do this. A=[ 1 5 3 8 9 4 7 6 5 2 ]; B=[ 5 2 3 9 7 ...

más de 2 años hace | 0

Respondida
Why am I getting a red message when trying to run this code.
In the future, please don't post a picture of your code, post your code itself (formatted using the first button of the Code sec...

más de 2 años hace | 0

Respondida
Issue with delete(obj)
Rather than creating and deleting a scatter plot over and over again, I think either using the comet function (if you have all t...

más de 2 años hace | 0

Respondida
Direct calculations on tables - elementwise mean of n-tables
Is there a simpler way? Yes. If you know that your data cell array is not empty, just use a for loop. n = numel(data); if n >...

más de 2 años hace | 0

Respondida
MCC/deploytool and excluded class
From the documentation "MATLAB Runtime only works on MATLAB code that was encrypted when the deployable archive was built. Any f...

más de 2 años hace | 0

| aceptada

Respondida
Matlab on two computers, one at work and one in laptop
It depends on the terms of your license. Check with your license adminstrator (if you're using your company's or educational ins...

más de 2 años hace | 0

Respondida
Hi When I run my code I got an error message "Invalid expression. Check for missing or extra characters" for my if loop. I am not sure why. Someone there can help me?
u1 = @(x, y, t) 0 u2 ... = @(x, y, t) 0 % u3 % = @(x, y, t) 0 Don't split the code among multiple lines (as u1), or if you...

más de 2 años hace | 0

Respondida
Why is dot (".") not considered an operator?
This documentation page lists it in the "Special Characters" section. [To be fair it also lists the colon operator in that table...

más de 2 años hace | 1

Respondida
Question regarding the calling of cfit coefficients
The way you gave, asking for the a, b, and c properties of the cfit object named fitobject, is one way to get the coefficients. ...

más de 2 años hace | 0

| aceptada

Respondida
Insert zeros in random positions following another zero
You can use repelem to replicate the elements. X = [2 1 0 4 5 0 778 90 0 3 88 0 77 66 0 12 23 0 45 80 0 89 67 0 34 67 0 76 32 0...

más de 2 años hace | 0

| aceptada

Respondida
Find function misbehaves when Indexing into array
%{ if isempty(FindIndex) FindIndex = 125; end %} Rather than assuming that your x array (and your y array) has exactly ...

más de 2 años hace | 1

Respondida
Webinar link not emailed after registration
If you've checked that your spam filter didn't trap the emails from MathWorks, please contact Customer Service directly using th...

más de 2 años hace | 0

| aceptada

Respondida
Outerjoin: resulting table has repeated rows and has erased some data
Rather than storing your data as tables with one variable containing serial date numbers, consider converting those serial date ...

más de 2 años hace | 0

Respondida
Using output of the fit function in further calculations
If all you want to do is evaluate the surface fit there's no need to break it into its components parts and re-assemble it. I'll...

más de 2 años hace | 0

| aceptada

Respondida
Locally suppress Code Analyzer warnings?
See the "Adjust Code Analyzer Message Indicators and Messages" section on this documentation page.

más de 2 años hace | 0

Respondida
How to make only x-axis invisible (y-axis stays visible)?
This wasn't an option when the question was originally asked, but now you can change the Visible property of the appropriate rul...

más de 2 años hace | 0

Respondida
Renaming output files so as not to overwrite when name is duplicated
There is a function named matlab.lang.makeUniqueStrings that may be of use.

más de 2 años hace | 0

Respondida
How do I use Matlab Compiler SDK to create executable for GUI app
I would try writing and deploying a function that opens the app then waits for the app to close before the function returns. Som...

más de 2 años hace | 0

Respondida
How to type sin function with square
While the usual mathematical notation to compute the square of the sine of x is , the MATLAB code to perform that computation is...

más de 2 años hace | 0

Respondida
What is the logic in the way plots are handled in Live Scripts?
From the documentation for the subplot function: "subplot(m,n,p) divides the current figure into an m-by-n grid and creates axes...

más de 2 años hace | 1

| aceptada

Respondida
I'm calculating using the order 3 polynomial interpolation method. But why does an array appear?
When you receive warning and/or error messages please show the full and exact text of those messages (all the text displayed in ...

más de 2 años hace | 0

Respondida
Is this possible, " 3D Printing with MATLAB ". If so, How far I could go with it ?
There are some old blog posts where people have discussed creating shapes in MATLAB and converting them into the file format use...

más de 2 años hace | 1

| aceptada

Respondida
How do I solve an ode and plot a graph of two terms within the ode
eta0 = 8080; lambda = 1.109; gamma = logspace(-3, 3, 100); f = @(t,tau)(-(tau+eta0*gamma)/lambda); f is already a function h...

más de 2 años hace | 1

| aceptada

Respondida
Why didnt get the same result even when using RNG function?
Suppose you stack a deck of cards in a particular way. You then play a hand of standard five-card draw poker with 3 players. You...

más de 2 años hace | 0

Respondida
Pass a plot handle into a function argument
Another way to control what is or is not included in the legend, if you have (through calling plot with an output argument) or c...

más de 2 años hace | 0

Respondida
Generating standalone application from app designer
Yes, either as a deployed web app or as a standalone desktop application. See this documentation page for more information.

más de 2 años hace | 0

| aceptada

Respondida
ode45 not working
Don't use global variables. Parameterize your function instead. The way you've written your funcionMAT file, it is a script fil...

más de 2 años hace | 0

Cargar más