Community Profile

photo

Stephen23


自 2014 起处于活动状态

Suspensa Vix Via Fit

统计数据

All
  • Most Accepted 2023
  • Most Accepted 2022
  • Personal Best Downloads Level 5
  • Editor's Pick
  • Most Accepted 2021
  • Grand Master
  • First Review
  • 5-Star Galaxy Level 5
  • GitHub Submissions Level 3
  • First Submission
  • 36 Month Streak
  • Thankful Level 5

查看徽章

Content Feed

排序方式:

已回答
How do I insert a substructure within an existing structure at a specific index
"What is the simplest way to do this?" With a structure array this would be easy with some indexing. It would also make accessi...

9 hours 前 | 0

已回答
Confusing sprintf() behavior
"Is this a bug?" No. SPRINTF and FPRINTF apply the entire format string to the data values, repeating the entire format string...

11 hours 前 | 1

| 已接受

已回答
concatenate multiple 'OutputFcn' options in odeset?
Define a wrapper function to call whatever functions you want. Note that the wrapper function itself will need to fulfill the r...

4 days 前 | 1

| 已接受

已回答
Plotting matrix data without existing x-values.
S = load('befolkning2019.mat'); M = S.befolkning2019 X = 0:size(M,1)-1; plot(X,M) legend('male','female')

5 days 前 | 0

| 已接受

已回答
Creating 25 x 2 matrix with each row range is 20
m = (0:20:499).' + [1,20]

6 days 前 | 1

已回答
Deleting specific repeating sequence from a column vector
"Might there be a more elegant solution?" You don't need a loop, just remove them all at once e.g.: Data = [ 0 %Pac...

7 days 前 | 0

| 已接受

已回答
Writing code to call functions
"I don't think I've learned how to properly call functions because I keep getting errors when trying to run function." The prob...

8 days 前 | 1

| 已接受

已回答
How to calculate and display electricity used in a month using fprintf?
Note that the assignment does not require that you also print the number of kWH, only the charge is required: n = input('How ma...

10 days 前 | 0

| 已接受

已回答
I just want to run my script within a certain time periodically. That's it all ....
Use https://www.mathworks.com/help/matlab/ref/timer.startat.html This is the function that lets you specify an absolute time ...

11 days 前 | 1

已回答
Why is my table being saved in a wrong way in a CSV file?
"Why is my table being saved in a wrong way in a CSV file?" Why do you think that MATLAB is doing something wrong? "but when I...

11 days 前 | 0

已回答
Split File paths by '\' but file paths have varying subfolders and thus lengths
Your code is very complex. You can simplify it by letting DIR recursively parse the folder structure. Lets try it here: mkdir ...

11 days 前 | 0

| 已接受

已回答
How to create struct of cell arrays
"I was wondering if this is the most "MATLABic" way of doing that" Yes. "...and why the following does not work" Because by d...

11 days 前 | 0

| 已接受

已回答
cheatsheet for dealing with structures?
"im trying to get all timestamps "timestamp" (for finding duplicate fields) of sub stucture "trainLocations" from every first ce...

12 days 前 | 0

| 已接受

已回答
importing multiple excel workbooks with multiple sheets into a cell array.
Based on my comment to your previous question: P = 'D:/foo/bar'; % absolute or relative path to the parent directory S = dir(f...

13 days 前 | 0

| 已接受

已回答
How to get specified data in table
Where T is your table: idx = strcmpi(T.OutputCase,'Pushover-x'); out = T(idx,{'StepNum','GlobalFX','GlobalFZ'}) https://www.m...

14 days 前 | 0

| 已接受

已回答
What is the fastest way to do repeated element wise matrix multiplication?
Reduce the number of operations inside the loop by replacing TIMES and SUM with MTIMES (of course adjusting the matrix/vector or...

15 days 前 | 0

| 已接受

已回答
Dealing data with text and numerical in .txt file
T = readtable('data.txt', 'Delimiter',{' ',':',','}, 'MultipleDelimsAsOne',true)

16 days 前 | 0

已回答
Struct field name with space or special character
"Is there a way to have space in structure field names?" No.

16 days 前 | 2

已回答
Editing csv data and convert it into a table
Lets fix the file so that it is formatted as a proper CSV file. Then importing it is trivial. S = readlines('EnergyLIS.csv') % ...

18 days 前 | 2

已回答
Convert double to datetime when importing .csv
T = readtable('Trace.csv', 'Delimiter',';', 'VariableNamingRule','preserve') P = wildcardPattern + "(X)"; F = @(n) datetime(n,...

18 days 前 | 0

| 已接受

已回答
how to automate this manual code containing if else conditons?
S = [1 1 1 1 2 2 2 2 2 2]; V{1} = [20 10 40 50 40 30 20 10 20 30]; V{2} = [10 20 30 20 10 30 20 40 20 30]; M = vertcat(V{:});...

18 days 前 | 1

| 已接受

已回答
Creating a colorbar in Matlab
"Is this colorbar automatic colors? As in Matlab picks its default colours?" Yes. The default colormap is described here: http...

19 days 前 | 0

| 已接受

已回答
Array indices must be positive integers or logical values. Error
x1= -2:0.01:2; % decimal comma -> point f1 = x1.^2-1; f2 = sin(x1); h1 = plot(x1,f1,'b',x1,f2,'r') % removed superfluous inde...

19 days 前 | 0

| 已接受

已回答
calling a function with struct inputs
"How can I call such a function" Because it neither displays anything nor returns any output it is not a very interesting funct...

20 days 前 | 1

已回答
using "&" with logical array
"why is not correct using &?" Who says that it is not "correct" ? What you show is not a code error (underlined in red), it is ...

20 days 前 | 0

| 已接受

已回答
How do I control the format of the date stamp on a plot axis with datetime values?
That is named the secondary label and has some rather rudimentary controls, e.g.: https://www.mathworks.com/help/matlab/ref/xse...

20 days 前 | 0

| 已接受

已回答
I don't know how to fix this, and I honestly don't know what caused this with chebfun
"...I honestly don't know what caused this with chebfun" You modified the function (perhaps accidentally) by adding some code o...

21 days 前 | 0

| 已接受

已回答
A bug? input: 1/0 output: -Inf
"A bug? input: 1/0 output: -Inf" Not a bug. Because your value x is actually negative zero not positive zero: https://en.wikip...

21 days 前 | 3

| 已接受

已提交


Number to Scientific Prefix
Convert a numeric value to SI-prefixed text (aka engineering / metric prefix). Bonus: binary prefixes!

21 days 前 | 15 次下载 |

Thumbnail

已提交


Scientific Prefix to Number
Convert SI-prefixed text (aka engineering / metric prefix) into numeric values. Bonus: binary prefixes!

21 days 前 | 12 次下载 |

Thumbnail

加载更多