Hello, 
Appreciate if someone can help with the below thinkscript. I am looking to show a plot on the chart on the day / bar of the highest volume of the past year. This script displays more than one day in the past year or sometimes doesn't display the plot at all .
def IsDaily = GetAggregationPeriod() == AggregationPeriod.DAY ;
def IsWeekly = GetAggregationPeriod() == AggregationPeriod.WEEK;
def Ismonthly = GetAggregationPeriod() == AggregationPeriod.MONTH ;
def length = if IsDaily then 252 else if IsWeekly then 52 else if Ismonthly then 12 else Double.NaN;
def highvol = Highest(volume, length);
plot top = if volume == highvol then 1 else Double.NaN;
top.SetPaintingStrategy(PaintingStrategy.TRIANGLES);
top.SetDefaultColor(color.WHITE);
	
		
			
		
		
	
				
			Appreciate if someone can help with the below thinkscript. I am looking to show a plot on the chart on the day / bar of the highest volume of the past year. This script displays more than one day in the past year or sometimes doesn't display the plot at all .
def IsDaily = GetAggregationPeriod() == AggregationPeriod.DAY ;
def IsWeekly = GetAggregationPeriod() == AggregationPeriod.WEEK;
def Ismonthly = GetAggregationPeriod() == AggregationPeriod.MONTH ;
def length = if IsDaily then 252 else if IsWeekly then 52 else if Ismonthly then 12 else Double.NaN;
def highvol = Highest(volume, length);
plot top = if volume == highvol then 1 else Double.NaN;
top.SetPaintingStrategy(PaintingStrategy.TRIANGLES);
top.SetDefaultColor(color.WHITE);
 
				 
						 
 
		 
 
		 
 
		