Drexel dragonThe Math ForumDonate to the Math Forum



Search All of the Math Forum:

Views expressed in these public forums are not endorsed by Drexel University or The Math Forum.


Math Forum » Discussions » Software » comp.soft-sys.matlab

Topic: help to save file from histogram
Replies: 3   Last Post: Nov 4, 2009 6:41 AM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]
uny gg

Posts: 30
Registered: 8/4/09
help to save file from histogram
Posted: Nov 3, 2009 11:06 PM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

Hello all

I am trying to save the histogram image as a file.. (any format e.g. png, jpeg. etc)
The problem is that I have to do this continuous many times..

Here is may code.

function dim = PatchDistHistogram(data)
dim = size(data);
nFeature = dim(2);

for i=1:nFeature
hist(data(:,i));
fname = ['astro' int2str(i) '.png'];
fname
print fname -dpng
end

end


When I run this code, it shows that each histogram in screen, however,
There is no file which is created from this.

I am not sure.. what is problem.

Could you please somebody help me with this?



Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© Drexel University 1994-2009. All Rights Reserved.
The Math Forum is a research and educational enterprise of the Goodwin College of Professional Studies.