treder / MVPA-Light

Matlab toolbox for classification and regression of multi-dimensional data
MIT License
70 stars 35 forks source link

mv_plot_topography issue #3

Closed MahHoss closed 6 years ago

MahHoss commented 6 years ago

Hi

I am using mv_plot_topography and I feel like line 139 should be

    set(gca,'Clim',cfg.clim); 

instead of the original

   set(gca,'cfg.clim',cfg.clim);

The way it was originally, I was not able to have cfg.clim = [-10 10] for example. The Matlab error lead me to line 139. I changed it and now it is working.

Also, I am wondering about the feature of plotting several topographies in one plot. Is there a possibility to have different titles for its subplots using the topography function? Using cfg.title I am only able to have the same title over each subplot.

Thanks!

Best wishes.

treder commented 6 years ago

This looks like a bug indeed, it should be fixed now.

Multiple titles should already be possible if you use a cell array e.g. cfg.title = {'title1' 'title2' 'title3'}. I adapted the docu to make this clearer and I just added in a new feature: the handles to the title objects are returned in h.title, so you can use get/set functions e.g.

set(h.title(1),'String','new title')

to change the title after the figure has been plotted. Hope this helps.

MahHoss commented 6 years ago

Great, thanks a lot!