Respondida
JSON decode / encode eats arrays
Not sure why Walter revived this old question but now that I've seen it: For the record, while inconvenient in the above scenari...

casi 7 años hace | 1

Respondida
Extracting Data from Cells
If you want to create a scatter3 plot using the coordinates from all the cells of Cross_sections, this is how I'd go about it: ...

casi 7 años hace | 0

Respondida
problem with "cd" and network drive
cd filepath is the command form of cd. The fact that filepath is purple is a hint that filepath is being treated as literal tex...

casi 7 años hace | 1

| aceptada

Respondida
Time series plot from structure array
but for the original data set tickers will have different number of dates so it will not be possible to put them in a table (I t...

casi 7 años hace | 0

| aceptada

Respondida
Using for loops in referencing
You don't even need a loop to perform your calculation: n = permute(0:5:40, [1, 3, 2]); %create a vector 0:5:40 in the 3rd dime...

casi 7 años hace | 1

| aceptada

Respondida
ActiveX compatibility problems in Matlab GUIDE application
Since you want to use your activex program in GUIDE, I assume it is an activeX control. If so, it is impossible to use a 32-bit ...

casi 7 años hace | 0

| aceptada

Respondida
Naming sheets with xlswrite
Have you looked at the documentation of xlswrite? xlswrite(filename,A,sheet) writes to the specified worksheet.

casi 7 años hace | 0

| aceptada

Respondida
What licence do I need to sell MATLAB/Simulink Online Course?
I would persevere with Sales. It's odd that they're not answering you. We don't work for Mathworks so whatever we tell you has n...

casi 7 años hace | 0

| aceptada

Respondida
Empty Figures because of empty variables
Right, since we're not getting the required explanation of what you're trying to do, here is how to calculate monthly latitude a...

casi 7 años hace | 0

Respondida
Community profile not updating
Yes, I've reported it to the devs half an hour ago. No reply so far, but it's still early at Mathworks.

casi 7 años hace | 2

| aceptada

Respondida
Save Excel cell range as image with activeX
With activex, you can do anything you can do with excel directly (as long as excel exposes it programmatically). So if you know ...

casi 7 años hace | 3

| aceptada

Respondida
How to update variable names after a "clear"
Unfortunately, this is a limitation of matlab's editor. Note that clear x is exactly the same as clear('x') The former is t...

casi 7 años hace | 0

| aceptada

Respondida
how I can delete 1.0e+03 in my answer
format shortg %or format longg should fix your display issue.

casi 7 años hace | 2

Respondida
In memory calculations with tall arrays from different databases
If you have R2019a, you can combine your two datastores. ds_1 = tabularTextDatastore('file_1.txt'); ds_2 = tabularTextDatastor...

casi 7 años hace | 1

Respondida
Removing data from a structure that is less than a certain threshold
This code seems to run very slowly The code you've posted either doesn' do anything because the if condition is never true, or ...

casi 7 años hace | 1

Respondida
What will be the output of of CD(1:8:8*16)=ciphertext
It simply replaces elements 1,9,17, 25, ..., 121 of CD by the elements of ciphertext. Since that's 16 elements of CD that are re...

casi 7 años hace | 1

| aceptada

Respondida
How to run macro in a different workbook
If the macro is supposed to act on the first workbook, the only way your excel procedure can work is if the macro rely on the Ac...

casi 7 años hace | 2

| aceptada

Respondida
Sort Through Cell And Put Corresponding Values In Their Respective Rows
This is how I'd do it: data = readtable('ML_Q_1.xlsx', 'ReadVariableNames', false); %optionally, give better name to the varia...

casi 7 años hace | 1

| aceptada

Respondida
How to split a table based on date and hour
The easiest way is to use retime (requires a timetable) or groupsummary grouping by day, Of course, for matlab a day starts at 0...

casi 7 años hace | 2

| aceptada

Respondida
Write a program to calculate the probability of two fair dice having sum equal to 7. There are two fair dice and we are interested in seeing whether the sum of the two fair dice having sum equal to 7. Use Monte Carlo Simulation.
Everything is fine with your code (although the calculation of n7 and nAll could be done with no loop at all), except for your c...

casi 7 años hace | 1

| aceptada

Respondida
Dot indexing is not supported for variables of this type in a for loop
Typically, you'll get this error because the structure or object you're indexing with . is empty. Indeed, you have this bit of ...

casi 7 años hace | 0

| aceptada

Respondida
How can I create a (printable) image (jpeg, bitmap, tiff...any format is ok) starting from a binary code?
I understood that it's an art project but I'm worried that you're going to be disappointed with the results if you don't come up...

casi 7 años hace | 0

Respondida
please help me run this code, as i am unable to solve an error.
There are a few issues with your code: you correctly query the size of your image and use that to preallocate your arrays, th...

casi 7 años hace | 2

| aceptada

Respondida
Keep positive real values from a cell inside a matrix
I want to scatter all the positive real values of every cell In that case, I would convert your cell array to a 3D matrix. As I...

casi 7 años hace | 0

| aceptada

Respondida
Swapping Letters Using Regular Expression
>> text = {'Fred', 'Replace', 'Cannot'}; >> regexprep(text, '([^aeiou]*)([aeiou])(.*)', '$1$3$2') ans = 1×3 cell array ...

casi 7 años hace | 0

| aceptada

Respondida
How to state that at least 80% of the values in my vector need to be positive
if mean(yourvector(150:end) > 0) >= 0.8 %assuming positive means strictly greater than 0 startindex = find(yourvector(150:...

casi 7 años hace | 0

Respondida
How to remove all the rows if first two columns has same number?
Two of many possible ways: yourmatrix(diff(yourmatrix(:, [1 2]), [], 2) == 0 , :) = []; yourmatrix(yourmatrix(:, 1) == yourm...

casi 7 años hace | 0

| aceptada

Respondida
How to use Uniquetol without sorting?
[~, colindices] = uniquetol(A', 1e-6, 'ByRows', true); %get indices of unique value. Is sorted BY VALUE B = A(:, sort(colindi...

casi 7 años hace | 0

| aceptada

Respondida
how binary floating point to real decimal number representation ?
Yes, as Stephen said, be careful about the difference between binary numbers and IEEE storage. You can easily see the IEEE repre...

casi 7 años hace | 2

| aceptada

Respondida
Interaction between MATLAB 32bit and MATLAB 64bit
I'm not clear why step 1 requires a particular bitness. The majority of databases will provide a 32-bit and 64-bit ODBC driver. ...

casi 7 años hace | 0

Cargar más