image thumbnail


version (2.06 KB) by Andri M. Gretarsson
chose the color and style of grid lines in a figure


Updated 01 Sep 2006

No License

Creates a new set of axes containing the colored grid, immediately behind the current axes. To make the axes with the grid visible, the current axes are made transparent and the current axes grid is removed. If any colored grid axes are in use when this function is called, it first deletes these old grids, before adding new cgrid axes. That way figure children don't multiply.

<gridaxishandle>=cgrid(<colorarg, stylearg, colorargy>)

Cite As

Andri M. Gretarsson (2021). cgrid (, MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R14
Compatible with any release
Platform Compatibility
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!