Mostrar comentarios más antiguos
Hi,
I am experiencing difficulties with setting up the axes limit for two plots I want to have in one figure. I can do each independent from the other and it will work so I don't have issue with the actual code functionality, the problem comes when I want to plot them both in one graph. I read the cla, to clear the axes and plot the other one but this one got rid of the old axes completely.. My code is below and I would like to ask for assistant.. I am pretty sure my problem is with the setting up the limits in the axes, because for the estimate function it will not be the same limits as the current data I have it could need to exceed the limits either in the positive or negative side.. !
data = importdata('test.dat');
x = data(:,1);
hold on
X = (x).';
a= min(X);
b=max(X);
line(repmat(X,2,1),repmat([0;1],1,length(X)),'color','r' );
axis([a b 0 40]);
[xi,f]=ksdensity(X)
plot(f,xi)
4 comentarios
Susan
el 31 de Jul. de 2011
Oleg Komarov
el 1 de Ag. de 2011
save it as .png then upload it to one of the repositories listed here: http://www.mathworks.com/matlabcentral/answers/7924-where-can-i-upload-images-and-files-for-use-on-matlab-answers
(I use tinypic). After you get the link to the image enclose it:
<<http://...>>
With a blank line before.
Jan
el 1 de Ag. de 2011
@Susan: This is your 21th question here. So I suggest to follow the blue "? Markup" link on this page to learn more about using MATLAB Answers.
Walter Roberson
el 1 de Ag. de 2011
The << >> markup has to be in a paragraph of its own, nothing else in the paragraph at all.
If you use imageshack the URL you are normally given will end with a slash. If you try to use << >> on that URL, it will not work. You need to display the image in another window, and left-click on the image myself and use "copy image location", and paste that URL in the << >> . Note: if the URL you get is an https:// URL instead of an http:// URL then you cannot use << >> successfully for it.
Respuestas (0)
Categorías
Más información sobre Creating, Deleting, and Querying Graphics Objects en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!