I would like to draw in grey color a certain part of the background in a plot. I know how to change the background color of the whole plot.I used this code after the plot function:
HANDLE = gca
get( HANDLE );
set( HANDLE, 'Color', [0.7,0.7,0.7] )
Exemple: y=x^2
How can I do to draw the blue part of the background in grey and to leave the other parts in white?
Thank you in advance
You can always draw a filled 2D rectangle with the desired color:
rectangle('Position',[-5,400,10,400],'FaceColor',[0.7,0.7,0.7])
So:
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.