Skip points in plotting error bars

Hi

I would like to know if there is a simple way to only show error bars every
n
points, so that the plot is a little less crowded.

Brute force way would be to plot the same wave twice with a mask wave modulo
n
applied to the one with error bars ?
Here is a macro to do this. The name is a bit misleading...


Macro ReduceErrorBars (sourceName, factor)
	String sourceName
	Prompt sourceName, "Source Wave", popup WaveList("*", ";", "")
	Variable factor=10, n=1, count=1, npoints
	Prompt factor, "Keep every nth point"

	npoints=numpnts($sourceName)
	PauseUpdate; Silent 1

	Do
		If (count!=n*factor)
			$sourceName[count]=nan
		else
			n+=1
		endif
	count+=1
	while (count<=npoints)
End