Page 1 of 1

Comands for MatLab

Posted: October 22 2007
by Mario Acero
Hello,

I would like to make some Log-Log plots (actualy, Log-Log contours) using the results given by GetDist, may be by changing some of the comands in the MatLab (*.m) files.
I've been looking for in some MatLab manual, but I have not been able to find the procedure.
For example, let me put here a piece of the 'root.m' file which produces a contour of parameter 20 vs. parameter 6:

Code: Select all

pts=load (fullfile('plot_data/','free_N_fnu_2D_20_8'));
tmp = load (fullfile('plot_data/','free_N_fnu_p8.dat'));
x1 = tmp(:,1);
tmp = load (fullfile('plot_data/','free_N_fnu_p20.dat'));
x2 = tmp(:,1);
load (fullfile('plot_data/','free_N_fnu_2D_20_8_likes'));
cnt = load (fullfile('plot_data/','free_N_fnu_2D_20_8_cont'));
[C h] = contour(x1,x2,pts,cnt); 
Then, what I want to do is to put the axes in Log scale.

Is it possible?

Thanks for your help.
Best,

MarioAAO.

Comands for MatLab

Posted: October 23 2007
by Han Jiaxin
Have you tried this

Code: Select all

set(gca,'XScale','log','YScale','log')
Regards,
Jiaxin