回答済み
I have a matrix and a Structure array. I want to export them as an Xlsx file, with the matrix on sheet one and the Structure array on sheet two
writematrix(cell2mat(struct2cell(structName)), 'filename.xls', 'Sheet', 1); writematrix(rankine, 'filename.xls', 'Sheet', 2); ...

1年以上 前 | 0

| 採用済み

回答済み
Plot index of for loop
I used annotation because accepts normalised units, otherwise text might be a better option. Have a look at it. Also I stronlgy...

1年以上 前 | 0

| 採用済み

回答済み
run loop once with a click on push button
If I understood correctly, you want to extract one name from a list of names. In this case you don't need a loop. At first glan...

1年以上 前 | 0

| 採用済み

回答済み
Help requested for generating an example for this kind of 3D plot
You can use surf to generate 3D meshes and inpolygon as binary mask to customise the shape of the base grid. % Number of grid...

1年以上 前 | 0

回答済み
find matching multiple condition
k will be true (or logical 1) if reset needs to be applied. false (or logical 0) otherwise. load('resettimehelp.mat'); curr...

1年以上 前 | 1

| 採用済み

回答済み
Using mat2cell in a proper way
When you use mat2cell, besides the first entry that is the matrix you want to modify into a cell, the other inputs give the inst...

1年以上 前 | 1

回答済み
How to change HH:mm:ss:SSS to HH:mm:ss.SSS for a column?
if the time format is imported from the .txt as a string, you can do the following using a for loop for every element: time = '...

1年以上 前 | 0

回答済み
problem in using meshgrid and how to show the variation of a parameter in the field
Your problem is related to the definition itself of pcolor. To quote the documentation: "The color of each face depends on ...

1年以上 前 | 0

回答済み
Filling the area in a plot without overlapping
You can select the number of plots and curves you want using nPlots and nCurves, respectively. You can also add more colors usi...

1年以上 前 | 1

| 採用済み

回答済み
how to create a time series from an excel data sheet containing hourly load in 1095 rows and 23 columns. no date or time in the excel data file.
According to the documentation, timeseries has to be either a scalar or a vector of scalars, therefore you can't use datetime. ...

1年以上 前 | 0

回答済み
Want to use nested For loop
You need to add a second dimension to your z array: n0 = 1; n1 = 2; n2 = 1; n3 = 2; d1 = 0.1; d2 = 0.2; lam = 3:0.01:7; ...

1年以上 前 | 0

| 採用済み

回答済み
Calculate Satellite TLE from Satellite Object
The reason why you haven't found a method is because it doesn't make sense physically. TLE are data format that condense inform...

1年以上 前 | 1

| 採用済み

回答済み
How to program a menu with callbacks upon selection?
Have a look at this simple app. You can selecte different voices from the menu bar and see the results on the GUI. Be caref...

1年以上 前 | 0

| 採用済み

回答済み
Generalizing Function Calls with Property Dependence in App Designer
Use: app.(prop_name).current to use strings as class properties (or structure fields).

1年以上 前 | 1

| 採用済み

回答済み
what @ does in MATLAB?
In this case @ is used to call a superclass method from a subclass. Consider the classes Food and Donut, such that Donut is a s...

1年以上 前 | 5

| 採用済み

回答済み
How to simulate number of visible satellite over the globe?
Depending on your needs and data, I suggest you to take a look at: contourf geocontourxy geoplot

1年以上 前 | 0

回答済み
How to eliminate for loop and perform the computation parallely?
%% Data: fs = 35000; T = 100; Nt = fs*T; M = 60; a1 = randn(M,Nt); a2 = randn(M,Nt); lambda = randn(1,Nt); B = randn(M...

1年以上 前 | 0

| 採用済み

回答済み
How can I make a set of stimuli composed of pseudorandom dots of the same size and each stimuli having different spatial frequencies/densities?
This is slow and inefficient and can be improven with more pseudo-random techniques, but it does the tricks: % Dots size: dotS...

1年以上 前 | 0

回答済み
Display elapsed time in hours, minutes, and seconds
time = seconds(4321) time.Format = 'hh:mm:ss'

1年以上 前 | 0

| 採用済み

回答済み
Image Rotation based of the location of four circles in the image
Assuming that you you have x and y coordinates of the centers: % Get centers' coordinates: xCenters = centers(:,1); yCenters ...

1年以上 前 | 0

| 採用済み

回答済み
How to create a 3d mesh with a unique property for every element?
You can store all the information you want into a structure: nElements = 25; x = rand(nElements, 1); y = rand(nElements, 1)...

1年以上 前 | 0

回答済み
compare matrices of different sizes
Hard to tell from the information you give, but it looks like you are using vectors as interpolation base, when you have to use ...

1年以上 前 | 0

| 採用済み

質問


Asymmetric intervals built-in vectorisation
Does Matlab have a built-in methodology to vectorise the following? a = [3,4,3,6,4,2]; b = zeros(1, sum(a)); idxEnd = cumsu...

1年以上 前 | 1 件の回答 | 0

1

回答

回答済み
How to add together values in matrix and replace the empty spaces with zeroes
in = [0 0 0 2 3 4 0 0 0 5 2 1]; out = zeros(size(in)); sum = 0; for j = 1 : length(in) if isequal(in(j),0) && ~isequ...

1年以上 前 | 0

回答済み
How can I establish communication between my matlab app and an electronic system wirelessly
Matlab supports Bluetooth Communications. See Documentation and Example.

1年以上 前 | 0

回答済み
I have a problem with appdesigner, can you help me?
I must say that is really hard to help you with so little infromation. If you don't need real time sharing you can pass the dat...

1年以上 前 | 0

回答済み
speed up for loop
Try parallel computing: % Get CPU's numebr of cores: [~, numberOfCores] = evalc('feature(''numcores'')'); % Start parallel ...

1年以上 前 | 0

回答済み
How to generate non repeat integer?
% Input data: numberOfElements = 15; numberOfGroups = 3; % Pre-process: elementsPerGroup = numberOfElements / numberOfGrou...

1年以上 前 | 1

| 採用済み

回答済み
Write a script to create a matrix B equal to A, but with its last column equal set to 0.
I suppose you want to limit your case to bi-dimensional arrays. You can create a function which works for every matrix funct...

1年以上 前 | 0

| 採用済み

質問


3D animate plot of satellite in orbit around Earth
Hello. I am developing an app with app designer and I need to animate the plot of a satellite on a fixed orbit. In the followi...

2年弱 前 | 1 件の回答 | 0

1

回答

さらに読み込む