#NEWLINE# def __mul__( self , operand ) : #NEWLINE# #INDENT# if ( not isinstance ( operand , TimeSeries ) ) : #NEWLINE# #INDENT# return TimeSeries ( [ ( y , ( y * operand ) ) for ( x , y ) in self . points ] ) #NEWLINE# #UNINDENT# lookup = dict ( operand . points ) #NEWLINE# return TimeSeries ( [ ( x , ( y * lookup [ x ] ) ) for ( x , y ) in self . points if ( x in lookup ) ] )