# Voss

Last seen: Today Con actividad desde 2013

Followers: 4   Following: 0

All

Ver insignias

#### Feeds

Ver por

Respondida
How plot a grid of rectangles on an overlaid circle?
R = 5; % circle radius L = 1; % horizontal grid spacing W = 2; % vertical grid spacing C = [7 8]; % center of the circle %...

alrededor de 11 horas hace | 0

Respondida
Normalising multiple columns of a matrix to a fraction of its maximum value
To divide each column by its maximum value: data_normalized = data./max(data,[],1); Example: data = rand(21,5); % random data...

alrededor de 12 horas hace | 0

Respondida
loop Will only open the files in starting folder
matFiles = dir(fullfile(pwd,'**','*.mat'));

1 día hace | 1

Respondida
Use fixed colormap or colorbar scale for series of 3D bar graphs in video animation
See clim: https://www.mathworks.com/help/matlab/ref/clim.html

1 día hace | 1

Respondida
Barchart colorbar colors from second vector
You need to set the colormap of the figure or axes. %% clear close all clc ids1 = [2,4,5,6,8]; meanVals = [0.2,0.204,0...

1 día hace | 0

Respondida
Returning data from uibutton callback
An easy way to make the callback update the value of t is to nest the callback function inside the main function (which requires...

2 días hace | 0

Respondida
Custom colorbar labeling centered on colors
f = figure; set(gca,'xtick',[],'xticklabel',[],'ytick',[],'yticklabel',[],'color','w'); set(f,'units','pixel','position',[70,7...

2 días hace | 1

Respondida
Why is it doing all 100 attempts as a singular go?
Your code does the same thing 100 times because the random values don't change from one iteration to the next. I guess you woul...

2 días hace | 0

Respondida
Speed up Some Code
% generate and collect all the P's first nJ = numel(J); P = cell(1,nJ); for ii = 1:nJ P{ii} = randperm(k,J(ii))+1; end ...

2 días hace | 0

Respondida
how to aviod the two loops
[X,Y] = meshgrid(x,y); A = [X(:),Y(:)];

3 días hace | 0

Respondida
how to use "range" in uislider
s = uislider(fig,"Limits",[1 50]); <https://www.mathworks.com/help/matlab/ref/matlab.ui.control.slider-properties.html>

3 días hace | 1

Respondida
str2num is returning and empty matrix: []
You don't need to use cell2mat; just use curly braces to get the contents of a cell in a cell array. For example: datetempDat ...

5 días hace | 0

Respondida
str2num is returning and empty matrix: []
There may be a character you don't see, at the beginning of the file, which is included by importdata at the beginning of the fi...

5 días hace | 0

Respondida
How do i extract a column from an array
This stores the 3rd column of the array A as Col1 (and displays Col1 in the command window): Col1 = A(:,3) Is that what you wa...

5 días hace | 0

Respondida
graph multiple excel or csv files
% get info about the (4) files S = dir('*.xlsx'); % construct full path file names filenames = fullfile({S.folder},{S.name}...

5 días hace | 0

Respondida
Different Output value of Functions
Implementation 1 has x*y^2 in the third term; Implementation 2 has x1*x2^3 in term3. f_value = (1.5- x+ x*y)^2 + (2.25 - x + x*...

6 días hace | 0

Respondida
Placing transparent rectangles on top of a plot
It's hard to say for sure what the problem is without the data, but one problem might be that the axes Y-Limits are outside wher...

6 días hace | 1

Respondida
How do I use only one legend entry for sets of xlines?
One way is to explicitly state which line objects to put in the legend, in the call to legend. For example: subplot(3,1...

6 días hace | 1

Respondida
Plot two areas of logarithmic plots
load('data_x.mat') figure; plot(x1,y,'b','Linewidth',1); hold on; plot(x2,y,'r','Linewidth',1); set(gca,'xscale','log','...

6 días hace | 0

Respondida
Variable Browser Tab Issue
It looks like the Variable Browser for that particular variable became undocked. See the following answer for how to dock it aga...

7 días hace | 0

Respondida
Need help in MATLAB tiled layouts (nested)
Something like this? t=tiledlayout(2,2); [X,Y,Z] = peaks(20); % Tile 1 t1=tiledlayout(t,1,2); nexttile(t1) surf(X,Y,Z) ne...

7 días hace | 1

Respondida
how to create array datetime
load matlab_A A hh = floor(A(:,4)/100); mm = mod(A(:,4),100); ss = zeros(size(A,1),1); B = [A(:,[1 2 3]) hh mm ss]; D ...

7 días hace | 1

Respondida
Overlaying three functions on a single plot
To avoid the error, use element-wise multiplication (.*), because * is for matrix multiplication. https://www.mathworks.com/hel...

7 días hace | 0

Respondida
>> qardl(data, ppp, qqq, tau) Unrecognized function or variable 'data'.
To run this function, you'd need to supply the inputs data, ppp, qqq, and tau. These are described in the comments at the top of...

8 días hace | 0

Respondida
Why does the tiledlayout keep the whitespace between tiles although TileSpacing is 'tight'
I guess the "tiled" part of "tiledlayout" implies that all contained axes are the same size and that the amount of space between...

8 días hace | 0

Respondida
Crashing on size(img)
You have a variable called "size". If this is a script, do clear size and then run the script again. If this is a ...

8 días hace | 1

Respondida
Sort Table Variable with Cell Arrays
t = table(t1,t2); [~,idx] = sort(t1(3:end)); t = t([1; 2; 2+idx],:);

8 días hace | 0

Respondida
Why is my code seemingly ignoring some of the for loop commands?
d is computed anew on each iteration of the for loop; thus after it's done the result you see is the last d that was computed, e...

9 días hace | 1

Respondida
Error due to not enough input arguments in ' C_c = cold.m_dot_c*Cold.c_p_c; %W/K '
The function find_UA expects two inputs. If you provide fewer than two inputs (e.g., by clicking the green Run button in the MAT...

10 días hace | 0

Respondida
How can I display a line in 3D with a colour gradient?
n = 10; x = linspace(1, 2, n); y = cos(x); z = y.^2; points = [x' y' z'] surf(points(:,[1 1]),points(:,[2 2]),points(:,[3...

10 días hace | 2