Community Profile # Voss

Last seen: Today Actif depuis 2013

#### Statistiques

All
• • • • • • • • • • • • #### Content Feed

Afficher par

A répondu
why do i receive "Unable to perform assignment because brace indexing is not supported for variables of this type".
Brace indexing (using {}) is for cell arrays (or tables), but FYPdatabase is a numeric array, so that's why the error happens. ...

environ 19 heures il y a | 0

A répondu
How can i call exact cell value from excel to edit field value in Matlab App
Use curly braces {} to get content from the table t: app.MassEditField.Value = t{2,"Var2"}; app.ForceEditField.Value =t{13,"Va...

26 jours il y a | 0

| A accepté

A répondu
Saving a matrix to a series of different created folders
for part = 1:3 BoolMat1 = [1,1,1]; dir_name = sprintf('C%g',part); mkdir(dir_name) f...

environ un mois il y a | 0

| A accepté

A répondu
How can I calculate the index of when the sequence starts to repeat?
The idea here is to successively check whether V is the same as a repeated sequence of its first T elements. Starting with T = 1...

2 mois il y a | 1

| A accepté

A répondu
Caesar's cypher working incorrectly
I can't find the function islower in MATLAB. Maybe that's a function you wrote yourself, and if so maybe it works correctly, but...

2 mois il y a | 0

A répondu
How do I loop over all columns in a cell array?
load('balls_data.mat') balls_data is a cell array of cell arrays, except for two cells, which contain empty 0-by-0 numeric matr...

2 mois il y a | 1

A répondu
App designer Edit field, position
pos1 = "[1 2 3 4]"; pos = str2num(pos1)

2 mois il y a | 0

| A accepté

A répondu
Trying to answer a math problem using newton's method but having problem in the function.
Multiplication is * or .* but never . as in 4.x and never implicit as in (x^2)z log10 is base-10 logarithm. log is natural loga...

2 mois il y a | 0

A répondu
How to delete a specified string value in a nested cell array
If AOI is a cell array of cell arrays of character vectors, like this: AOI = {{'AOI 1';'AOI 2';'NO AOI';'AOI 3'}; {'NO AOI';'NO...

2 mois il y a | 0

| A accepté

A répondu
I want to use fprintf to make a table of results
fprintf(' %6.3f %6.3f\n', [standard, average].')

2 mois il y a | 0

A répondu
How to create multiple structure variables and assign values to them at one line.
One way: [AC.a, AC.b] = deal(5, 15); AC Another way: C = {5, 15}; [AC.a, AC.b] = C{:}; AC https://www.mathworks.com/h...

2 mois il y a | 0

A répondu
How to append cell arrays to from a unique array and then fill one of its column out with data from excel sheets?
Obviously if you just wrapped that code in a loop, your variable stations1 would be overwritten on each iteration of that loop, ...

2 mois il y a | 0

| A accepté

A répondu
How can I fix the error: Index exceeds the number of array elements (1)?
clear B_n = -5.36; omega_d = 400; zeta = 29; tt=0.01; upTo_t=10; N = upTo_t*100; total = zeros(N, 1); t=0.01*(1:N); f...

2 mois il y a | 0

| A accepté

A répondu
How can I replace a certain pattern in a string?
One way: oldstr = 'abbabba'; oldp = 'abba'; newp = 'aaaa'; newstr = regexprep(regexprep(oldstr,oldp,newp),oldp,newp);

2 mois il y a | 0

| A accepté

A répondu
Merging strings in a table
L = readtable( fileLog ); L2 = convertvars(mergevars(L,["Var2","Var3"]),"Var2",@(a)join(a," "));

2 mois il y a | 0

A répondu
How can I add the elements ascending in this code
B = Mf-cumsum(D);

2 mois il y a | 0

A répondu
Error in for loop (issue with variable calling)
Time{i} is all the times from the file. To get the times of the peaks found by findpeaks, index Time{i} with the peak locations ...

2 mois il y a | 1

| A accepté

A répondu
Index of element to remove exceeds matrix dimensions
Let's examine what happens on the first iteration of that for loop. for i = 1:Np First time through the loop, i is 1. idx...

2 mois il y a | 0

| A accepté

A répondu
a file called avehighs.dat stores for three locations
Instead of looping over months, (for i = 1:12), you can plot all the months for a given location at once, and loop over location...

2 mois il y a | 0

| A accepté

A répondu
Create plot with shaded standard deviation, but ...
data = readmatrix("data.xlsx") % matrix with 3 columns % columns 2 and 3 are shorter, so i ignore NaN values avg_data = mean(...

3 mois il y a | 2

| A accepté

A répondu
How to remove unrecognized function or variable error
<https://www.mathworks.com/help/matlab/matlab_prog/share-data-between-workspaces.html>

3 mois il y a | 0

A répondu
How I do overlay 2 Matlab fig files?
f1 = openfig('trajectory id_88092.fig'); f2 = openfig('trajectory id_90788.fig'); leg = findall(f2,'Type','legend'); leg.Au...

3 mois il y a | 0

| A accepté

A répondu
Fplot command only displaying a limited range. It displays [0,1] even though the range requested is [0,30].
fplot is sending a vector t to your function, not a scalar t. This causes an error if/when it gets to the first &&, which only h...

3 mois il y a | 1

| A accepté

A répondu
Bar plot of categorical data
histogram seems to work fine: data = randi([0,7],46,1); histogram(data) Maybe you have another function called histogram th...

3 mois il y a | 0

| A accepté

A répondu
calculate the maximum at each point of the grid
PP_temp = [P_1_4, P_1_6, P_1_9, P_2_2, P_6, P_7, P_8, P_9, P_10]; PP_max = max(PP_temp,[],2);

3 mois il y a | 0

| A accepté

A répondu
how to calculate the maximum of a probability array
PP_temp = [P_1_2, P_1_6, P_1_9, P_2_2, P_6, P_7, P_8, P_9, P_10]; PP_max = max(PP_temp,[],2);

3 mois il y a | 0

| A accepté

A répondu
How to reference to a struct field with char array?
name = 'ABA'; idx = 1; TestUnits.A.(name)(idx).Values

3 mois il y a | 1

| A accepté

A répondu
I was using if and Elseif statements. Everytime I input the third option the print for the second option appears.
Adjust your parentheses so that the || conditions are checked together, then the &&: if (p1 == 'P' || p1 == 'p') && (p2 == 'r' ...

3 mois il y a | 0

A répondu
Pass plot parameters as a vector
x = linspace(0,1,10); % I changed the domain so you can see the lines y(1,:)= exp(x); y(2,:) = log(x); y(3,:) = x.^2; colors...

3 mois il y a | 0

A répondu
Projectile Motion when y0 does not equal 0
clear all close all clc g= -9.81; % gravitational acceleration angle= 45 *pi/180 ; % angle in radian % v0=2; % initial sp...

3 mois il y a | 0