MATLAB Answers


saving a data

Asked by FIR
on 29 Mar 2012

I havea data as

g =

    [1x4 double]
    [1x5 double]
    [1x4 double]
    [1x4 double]
    [1x4 double]
    [1x5 double]

please tell how to the values in each and i want to store those values in G




No products are associated with this question.

2 Answers

Answer by Jan Simon
on 29 Mar 2012
 Accepted answer

FIR, please, you have written over 100 questions in this forum. You should have learned already that it is impossible to answer "tell how to the values in each". There is no chance that we guess the problems you have with storing those values in G. What about:

G = g;

Is g a cell or is the shown block a copy from a text file?

I do not see a connection between the posted information and the subject "saving a data".

Please, FIR, be more careful with your questions. Reading the current message is a waste of the time of all, who want to help voluntarily.

  1 Comment

on 29 Mar 2012

in g when i view in variable editor i have

[1,2,3,8],like these i have for values in g

i can view these values in variable editor and i know how to display it for ex

for i=1:length(g)

these values are displayed in command window ,now i want to save these variables in G

Answer by Image Analyst
on 29 Mar 2012

I agree complete with Jan. So, tell us why did G=g not work. All the vectors inside your individual cells are a different size so it's not possible to stack them all into a 2D numerical display (unless you want to pad the smaller arrays so that they are the same size). Do you want to string them all together into a 1 by 26 vector? You must be more explicit so we don't waste time guessing around all the ambiguities in your message.

Also, there is a celldisp() function that you might want to use rather than disp().


Join the 15-year community celebration.

Play games and win prizes!

Learn more
Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

MATLAB Academy

New to MATLAB?

Learn MATLAB today!