답변 있음
how can I plot a graph over an image in Matlab?
You need to use the same axes. The easiest solution is to use hold, probably the line below will already do what you need: hold...

3년 초과 전 | 1

답변 있음
Accessing cell array contents
No. You could use cellfun, but that will only hide the loop. Using a loop directly tends to have better efficiency. But don't w...

3년 초과 전 | 1

| 수락됨

답변 있음
Can we read dicom files without extension using the dicomread function?
Store the read images in a 3D array. That way you will have the entire volume in one variable, allowing you to do further proces...

3년 초과 전 | 1

| 수락됨

답변 있음
My Matlab code (the same one) is running extremely slow on a fairly new and powerful PC and is running fast (10x times faster) on my weaker laptops
I started to write this as a comment, but I realized this makes more sense as an answer. These are the general trends for newer...

3년 초과 전 | 1

답변 있음
why I get the error "function 'lsqcurvefit' not supported for code generation" when using Matlab Coder?
Your code may be simple, but the code inside lsqcurvefit apparently is not. There are a lot of things happening in that function...

3년 초과 전 | 0

답변 있음
Matlab window/frame in different colors?
This touches on the call for a proper dark mode that is getting stronger and stronger. To my knowledge there are no such tool...

3년 초과 전 | 1

답변 있음
error in LINE 1 " function varargout = Final_gui(varargin) " ,while converting the code to C ,how do i fix it
Unfortunately you can't convert a GUI to C with coder. There are just too many elements that aren't supported. You can packag...

3년 초과 전 | 0

답변 있음
I have a matrix 592*2 from this I got a curve, now I need to calculate full width half maximum , how to do it?
# Find the maximum value and its x-value # use find() to find the first time the y is above 0.5*max # use find() on the secon...

3년 초과 전 | 0

답변 있음
update one plot in appdesigner
This code should work, once you fix the creation of the vector: 20:-1:1.

3년 초과 전 | 0

| 수락됨

답변 있음
How to convert R code in Matlab
Unfortunately, no. It is not possible to convert R code automagically to Matlab code. What you can do is call the R code from M...

3년 초과 전 | 0

답변 있음
Methods to create arrays of NaN
In very old releases (prior to v7 (R14)) it was not possible to create arrays with NaN and inf. In those releases you had to use...

3년 초과 전 | 0

답변 있음
Assign two variables to a SQL Query
I suspect you're missing a space before 'WHERE'. I can recommend using sprintf to avoid such errors.

3년 초과 전 | 0

| 수락됨

답변 있음
Create a function for set name, user, password for sql database
Why don't you use a variable that contains the password? Or a function that returns the password as a char array? That way you o...

3년 초과 전 | 1

| 수락됨

답변 있음
How to save fprint as a string in .mat file
If you want to store the text output you should use sprintf to create the formated text. Then you can use fprintf to print to th...

3년 초과 전 | 0

답변 있음
Install MatLab on a computer with a 64-bit operating system, ARM-based processor
If your hardware happens to a Raspberry Pi: I know there are things you can do with Simulink to deploy code to a Pi. I have neve...

3년 초과 전 | 0

답변 있음
Deleting Rows in Text File and Assigning them to a New Text
Read the text file with readlines (or my readfile function). Then you can use contains to determine which line contains the tex...

3년 초과 전 | 0

| 수락됨

답변 있음
Concatenate/ Merge two HEX Cell Array
You need to use vertcat instead, or use the semicolon. a={'01';'02';'03'} b={'04';'05'} c=[a;b] vertcat(a,b)

3년 초과 전 | 0

| 수락됨

답변 있음
Can we use multiple version of Matlab in same system. Ex: 2020b and 2022a together in one system
If you mean your operating system with the term system; absolutely. I currently have several releases of Matlab installed. It i...

3년 초과 전 | 1

| 수락됨

답변 있음
Forward optional args to another function
This is a terrible cludge. There must be a better way. If you don't find it, feel free to use this. It uses the fact that the x=...

3년 초과 전 | 1

답변 있음
Save for loop outputs into structure
You should probably use a struct array: allBIN(n).corr= ___ %etc But if you insist: field names must be valid variable names,...

3년 초과 전 | 0

| 수락됨

답변 있음
Converting string to function/number
The way to avoid eval in this case is to use str2func: f=str2func('cos'); f(pi)

거의 4년 전 | 1

답변 있음
How to concatenate 5x2 array output from my function?
This should already get you most of the way there: i = 0.5; for n = 1:100 Currents{n} = Dunn(mvs10, mvs30, mvs60, mvs100,...

거의 4년 전 | 0

| 수락됨

답변 있음
Is there any plugin that allows automatic tracking of history of all workspace variables?
Below is my initial implementation of what you need. There are a lot of adaptations still to be made. It implements both a vecto...

거의 4년 전 | 0

| 수락됨

답변 있음
is it possible to convert a python code to a matlab code ?, and if it is how?
The answer depends on the exact code. There is no automated conversion system that will work for all code (limited ones may exis...

거의 4년 전 | 0

답변 있음
Image usage from guide
There is a copyright notice at the bottom of the page. So unless otherwise stated elsewhere, you're not allowed to use this exac...

거의 4년 전 | 1

| 수락됨

답변 있음
is Dell 5580 core i5 2.80GHz 16GB 512GB SSD Intel HD Graphics 620 can run matlab 2021?
It seems to satisfy the minimum requirements mentioned on the <https://www.mathworks.com/support/requirements/matlab-system-requ...

거의 4년 전 | 0

답변 있음
Error using plot Invalid subscript for Y.
Let's generate some data and try my suggestion of casting to double: %generate data FO2_Odometer=rand(10,1);Caliper1=rand(10,1...

거의 4년 전 | 0

| 수락됨

답변 있음
Need ideas on how to extract a 30s portion of a wav file and save as a new file
Have you already found a way to read a single wav file? If not, audioread should do what you want. Remember that the second o...

거의 4년 전 | 0

답변 있음
Display mutiple lines in Text area in Matlab App designer
You are replacing the text every iteration. What you need to do is concatenate them. Start with an empty line before the loop, ...

거의 4년 전 | 0

답변 있음
Convert existing MATLAB script into GUI using app designer
The first step is to convert your code to a function. Then you can design your GUI to gather the necessary inputs for that funct...

거의 4년 전 | 0

더 보기