![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/188668/image.jpeg)
ECG-like grid on figure
3 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
Hello.
I have an ECG and i would like to set this kind of grid on my plot, dependent of the voltage and the time of the signal:
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/190720/image.png)
Thankyou
0 Commenti
Risposta accettata
Ameer Hamza
il 21 Mag 2018
You can set up your axis to a similar format using the following code
ax = axes
grid(ax)
grid(ax, 'minor')
ax.GridColor = [ 1 0 0 ]
ax.GridAlpha = 0.5;
ax.MinorGridColor = [1 0 0]
ax.MinorGridAlpha = 0.5;
In older MATLAB versions, use set() instead of dot notation to set axis properties.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/188668/image.jpeg)
Più risposte (0)
Vedere anche
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!