Respondida
How can I make a string array consisting of strings with numerical suffixes?
str2num won't work with a word ("sub"). It's also unnecessary if you are using sprintf. One other correction I would make is i...

más de 3 años hace | 1

Respondida
How to convert this mesh as 3d matrix?
Not exactly sure what the question is, but note that XYZ is not the same as (x,y,z). In XYZ, x and y values are your index numbe...

más de 3 años hace | 0

| aceptada

Respondida
how do i join 2 matrices
Yes, you could use vertical concatenation followed by reshape. a= rand(5) b=rand(5)+5 % brute force c = [a(:,1) b(:,1) a(:,2...

más de 3 años hace | 1

| aceptada

Respondida
Error using scatteredInterpolant on missing data
When using the syntax F = scatteredInterpolant(x,y,v), your inputs must all be vectors. That means v=z(:), and that x and y are ...

más de 3 años hace | 1

| aceptada

Respondida
How to train a neural network
The first result I found when googling your question seems promising: Create and Train a Feedforward Neural Network - MathWorks...

más de 3 años hace | 0

Respondida
Stacked bar chart is in alphabetical order instead of date.
Your dates are categoricals, which by default get stored in alphanumeric order. Use 'reordercats' to place them in your desired...

más de 3 años hace | 0

| aceptada

Respondida
How to Call a Function Within a Script?
Here is how you run the example you mention. Note that the last 2 lines of code in the example are how you call the function, an...

más de 3 años hace | 0

Respondida
Plot a time series for Mean temperature for january and february
See this answer: https://www.mathworks.com/matlabcentral/answers/1855768-finding-average-data-from-a-large-data-matrix#answer_1...

más de 3 años hace | 0

Respondida
Generating random variable of certain std and mean (Simple Task)
My suspicion is that the grader is expecting column vectors but you have created row vectors. Try this y = 4.2.*randn(20, 1) ...

más de 3 años hace | 2

| aceptada

Respondida
I am getting the error as "Too many Input arguments", " Failure in Initial Objective function evaluation" .Also unable to run the function vivek1
Using the following syntax (from your original post) will result in a "Too many input arguemnts" error because, well, there are ...

más de 3 años hace | 0

| aceptada

Respondida
Finding average data from a large data matrix
Use groupsummary. data = [1990 1990 1990 1990 1995 1995 1995 1995; 1 1 2 2 1 1 2 2; 1 2 1 2 1 2 1 2; 3 5 7 4 6 8...

más de 3 años hace | 1

Respondida
Extract data in a table following a a range of date (years)
Your table has 3 columns. Your deletion code must delete all 3 columns. You specify 'all columns' by adding a colon in the 2nd p...

casi 4 años hace | 0

| aceptada

Respondida
Unable to perform assignment because the left and right sides have a different number of elements. ODE45
The problem is that your calculation for yy(6) returns a 3x3 matrtix, and you are assigning it to a 1x1 space. Hence, the left (...

casi 4 años hace | 0

| aceptada

Respondida
Converting cell to array data with specific string
There are many ways to do this. Here are two. The result of the 2nd option is a table. See this page on Accessing Data in Tables...

casi 4 años hace | 2

Respondida
How to sum values from a table by category
I would use groupsummary. You may be interested in our Performing Calculations by Category video from our Exploratory Data Analy...

casi 4 años hace | 0

| aceptada

Respondida
plotting multiple fitting graphs in a single graph
By including the figure command, you are telling MATLAB to create a new figure window. Removing that and making some minor cosme...

casi 4 años hace | 0

Respondida
How to load excel file in numeric matrix and save it
Use readtable or readmatrix. You might be interested in Ch 10 of MATLAB Onramp.

casi 4 años hace | 0

Respondida
How to mean data of second column with respect to the similar element in the first column
Use groupsummary or grpstats. Group on column A, and set the 'method' to 'mean', and set the datavars to column B. If you impor...

casi 4 años hace | 0

Respondida
Finding average heart rate of EKG data
I would calculate the instantaneous heart rate for each heartbeat, and then take the average of those to find average heart rate...

casi 4 años hace | 0

Respondida
Create surf (3D plot) with axis limitation from 2D matrix - animated
Each time you call the surf function, you get a brand new axes. This means any settings set in the previous axes are lost, and m...

casi 4 años hace | 0

| aceptada

Respondida
How can I show the legend to all bars?
Legends label data series, not individual points in that data series. The issue right now is that each bar is part of a single d...

casi 4 años hace | 0

| aceptada

Respondida
How to colour each individual bar with a different colour?
See this answer: https://www.mathworks.com/matlabcentral/answers/1651280-changing-color-for-each-bar-plot

casi 4 años hace | 0

Respondida
how to insert webcam video on guide
Be sure you have the correct support package installed. https://www.mathworks.com/help/supportpkg/usbwebcams/ug/installing-the...

casi 4 años hace | 0

Respondida
Could anyone explain what is the role of vector x in, polarhistogram(deg2rad(200),x) ;given x=(0:10:360)*3.14/180 ?
Looking at the possible syntaxes for calling polarhistogram, I draw the following conclusions: For 1, x must be specifying the...

casi 4 años hace | 0

| aceptada

Respondida
Need to solve this with Runge-Kutta 4th order method in MatLab.
https://www.mathworks.com/matlabcentral/answers/?search_origin=ans_leaf&term=runge-kutta+4th+order

casi 4 años hace | 0

Respondida
I have file with size= 2728, 5. I use writematrix function to sale file in Excel file. If I read saveld file, it size becomes 2728, 2728.. What is wring?
Your syntax means the data is being writting to an existing spreadsheet, which seems to alreay have some data in it. readmatrix...

casi 4 años hace | 1

Respondida
Try to hide/show certain fields end with errors
You have added callback functions to your figure and your selection panel. Remove these, and the errors go away. To remove, rig...

casi 4 años hace | 0

| aceptada

Respondida
how can i plot this attached figure
Use plot3 and tiledlayout.

casi 4 años hace | 0

| aceptada

Respondida
plot all dates to x-axis in bar graph
d = datetime(2017,1:20,1); x = rand(1,20); bar(d,x) xticks(d)

casi 4 años hace | 0

| aceptada

Respondida
cleaning the outliers from a large data sets xlsx
If you process your data in a live script, consider interactively exploring different ways to detect and remove outliers using t...

casi 4 años hace | 0

Cargar más