matlab - Using custom colormap on contourf -


i have created colourmap 'mycmap' want use on every contourf in matlab. how this?

i have tried

[c,h]=contourf(xrange,y_range,capacity,14,'linecolor',mycmap'); 

but doesn't work. custom colour scale looks like:

mycmap =  0.9725    0.9725    0.9725 0.9442    0.9442    0.9442 0.9159    0.9159    0.9159 0.8876    0.8876    0.8876 0.8593    0.8593    0.8593 0.8310    0.8310    0.8310 0.8027    0.8027    0.8027 0.8002    0.8002    0.8002 0.7976    0.7976    0.7976 0.7950    0.7950    0.7950 0.7924    0.7924    0.7924 0.7204    0.7204    0.7204 0.6484    0.6484    0.6484 0.6484    0.6484    0.6484 0.6484    0.6484    0.6484 0.6329    0.6329    0.6329 0.6175    0.6175    0.6175 0.6021    0.6021    0.6021 0.5885    0.5885    0.5885 0.5750    0.5750    0.5750 0.5615    0.5615    0.5615 0.5480    0.5480    0.5480 0.5345    0.5345    0.5345 0.5210    0.5210    0.5210 0.5075    0.5075    0.5075 0.4940    0.4940    0.4940 0.4564    0.4564    0.4564 0.4188    0.4188    0.4188 0.4092    0.4092    0.4092 0.3995    0.3995    0.3995 0.3899    0.3899    0.3899 0.3802    0.3802    0.3802 0.3706    0.3706    0.3706 0.3609    0.3609    0.3609 0.3512    0.3512    0.3512 0.3416    0.3416    0.3416 0.3328    0.3328    0.3328 0.3239    0.3239    0.3239 0.3151    0.3151    0.3151 0.3063    0.3063    0.3063 0.2974    0.2974    0.2974 0.2886    0.2886    0.2886 0.2798    0.2798    0.2798 0.2771    0.2771    0.2771 0.2743    0.2743    0.2743 0.2716    0.2716    0.2716 0.2689    0.2689    0.2689 0.2661    0.2661    0.2661 0.2634    0.2634    0.2634 0.2607    0.2607    0.2607 0.2580    0.2580    0.2580 0.2552    0.2552    0.2552 0.2525    0.2525    0.2525 0.2498    0.2498    0.2498 0.2471    0.2471    0.2471 0.2196    0.2196    0.2196 0.1922    0.1922    0.1922 0.1647    0.1647    0.1647 0.1373    0.1373    0.1373 0.1098    0.1098    0.1098 0.0824    0.0824    0.0824 0.0549    0.0549    0.0549 0.0275    0.0275    0.0275      0         0         0 

thanks helping.

you invoke colour map after plotting...

[c,h]=contourf(xrange,y_range,capacity,14) colormap(mycmap); 

Comments

Popular posts from this blog

sql - Time in datatime field -

javascript - How to split the success output from an Ajax post? -

java - sharing object across different classes -