回答済み
Extract all data for the June months over the years from a timetable
Piece 'o cake -- granted, it takes a little while to get used to using grouping variables and all, but... load https://www.math...

3年以上 前 | 1

| 採用済み

回答済み
Unable to write data in already open .xlsx file
<microsoft.com Excel/use-shared-workbook> explains how to save a workbook as shared for simultaneous access. I've not tried thi...

3年以上 前 | 0

回答済み
How to close a dos window after a .exe is finished running?
Actually, the line [x, y]= dos(C:\\Users\jessi\Desktop\HydrusMC\H1D_CALC.exe); can't work -- the argument to dos must be a c...

3年以上 前 | 0

回答済み
Find that particular start index at which the atleast 6 points are consecutively increasing
For small sample size such as this, the string conversion route is probably as good as any... ERRATUM: Forgot that "-111" woul...

3年以上 前 | 0

回答済み
How to open file, clear content, rewrite conent and close.
DIR_working="C:\Users\jessi\Desktop\HydrusMC\Simulations\MC_"+[1:num_sim].'; writematrix(DIR_working,'C:\Users\jessi\Desktop\Hy...

3年以上 前 | 1

回答済み
Find values in a column that fall between two numbers
MATLAB requires compound logical tests be written separately...and you don't need find, just the logical result vector.. vLo=4;...

3年以上 前 | 1

| 採用済み

回答済み
I get wrong logic while I compare two datetimes
@Karim has explained why the logic test is correct because your inputs to isbetween are in the wrong order for the result to be ...

3年以上 前 | 1

| 採用済み

回答済み
How to calculate the small changes in a signal?
We've elsewhere determined the data are recorded as signed 16-bit integers which span +/-32K which is a 64K range. A default do...

3年以上 前 | 1

回答済み
How can I read a column from excel while I do not want all the data of that column?
It's VERY inefficient to open/read/close the same file three times, not to mention it just makes for more work to address multip...

3年以上 前 | 0

回答済み
Issues with readtable in 2022a but same line of code worked with 2018a
I've not yet updated past R2020b so can't check later releases -- but, it works seemingly just fine with R2020b (same warning re...

3年以上 前 | 0

| 採用済み

回答済み
Import options & loops for time series data
W/o the second Q?, my approach would be something like -- First, read, create the metadata table of auxiliary data... metadata...

3年以上 前 | 0

| 採用済み

回答済み
In "scatter"-related legends, how to make larger symbols ?
My experimenting with legend and scatter wasn't very fruitful; the legend was created with a given size (height, primarily the i...

3年以上 前 | 1

回答済み
Reading int16 from a file and writing as int8 to another file
Don't open/close the files inside the loop -- just read/write them sequentially... ... fidi=fopen('/home/read.bin','r'); % ope...

3年以上 前 | 0

| 採用済み

回答済み
I have issues using datenum function because of a different date format on excel, how can I modify my dates in matlab and then run the function?n
Don't use datenum, use datetime instead and readtable, You can either use an import options object from detectImportOptions in...

3年以上 前 | 1

回答済み
I don't want to include initial condition in the plot
Again, way too much code that has no bearing on the issue -- and you don't format your code so can be read on top of that -- we'...

3年以上 前 | 0

| 採用済み

回答済み
Separating and splitting table by numeric values and writing to multiple files
" split the grouped devices into seperate tables?" The short answer is "you don't!" Use the DeviceID variable as a <GroupingVa...

3年以上 前 | 1

| 採用済み

回答済み
calling a built-in private function
private functions are unable to be called from anywhere excepting either the folder containing the function itself (not the inte...

3年以上 前 | 2

| 採用済み

回答済み
Want to convert whole data in a binary/ text file in to binary digits
To use native I/o conversion, hex values must be preceded by '0x' so will either need to do that string substitution or read as ...

3年以上 前 | 0

回答済み
Finding the mean of each column of each double within a structure
Something like M=arrayfun(@(s)mean(s.Data(:,2:end)),beh_data,'UniformOutput',0).'; % calculate the means M=cellfun(@(c)struct(...

3年以上 前 | 0

| 採用済み

回答済み
How to find '1' for the second time in a matrix by row wise
Probably more efficient way to deal with the cell array indexing, but C=arrayfun(@(i)find(A(i,:),2),1:size(A,1),'UniformOutput'...

3年以上 前 | 0

回答済み
Only one graph appear instead of two.
You forgot hold on to put more on the same axes after the first... plot(T,Psat1,'r'); hold on plot(T,Psat2,'b'); title('Sa...

3年以上 前 | 0

回答済み
Search in a column based a result from another column
More pain when don't attach data to use, but... tData=table(categorical({'AMI';'NMI';'AMI'}),categorical({'Fiat';'Renault';'Ren...

3年以上 前 | 0

| 採用済み

回答済み
Force user to input an specific time format
Only with a lot of trouble -- use a datepicker UI control instead uidatepicker

3年以上 前 | 0

回答済み
How to replace zero with the values present in array
array=[34.9609375000000 37.9882812500000 34.9609375000000]; Dataset(deleted_data_idx,:)=repmat(array,1,size(Dataset,2...

3年以上 前 | 1

回答済み
Find differences between 2 tables
ix=(any(A{:,:}~=B{:,:},2)&all(isfinite([A{:,:} B{:,:}]),2))|(all(isnan(A{:,:})~=isnan(B{:,:}),2)); This is somewhat tricky beca...

3年以上 前 | 0

回答済み
How do I save data from a fprintf loop?
msgs=string(N,1); for ii=1:N .... msgs(ii)=compose(['\nDecoded Message = %2d\n Coded: Error rate = %1.2f, ' ... ...

3年以上 前 | 0

| 採用済み

回答済み
why xlswrite/xlsread is not recommended for use
See xlsread for the official word from TMW (The Mathworks). From the supporting link there is the following Advantages [of ...

3年以上 前 | 1

回答済み
generate mean, variance and std using built in function
stats=[[mean(A,2);var(A,2);std(A,2)]; [mean(A,1);var(A,1);std(A,1)];] will give you and array of the statistics by clas...

3年以上 前 | 0

回答済み
Trying to get certain values from an excel file
Perfect place for a table -- keeps everything together with variable IDs and you have access to everything as you need it. I do...

3年以上 前 | 0

回答済み
Is it possible to plot the 'i'th set of data from a switch case with a single block of code?
If it's the same code identically for each case but with a different dataset based on the index, that's all you need -- you don'...

3年以上 前 | 1

| 採用済み

さらに読み込む