#NEWLINE# def mean_random( self , idx = 'lastexog' ) : #NEWLINE# #INDENT# if ( idx == 'lastexog' ) : #NEWLINE# #INDENT# meanr = self . params [ ( - meanr . model . k_exog_re ) : ] #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if isinstance ( idx , list ) : #NEWLINE# #INDENT# if ( not ( len ( idx ) == self . model . k_exog_re ) ) : #NEWLINE# #INDENT# raise ValueError ( 'length of idx different from k_exog_re' ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# meanr = self . params [ idx ] #NEWLINE# #UNINDENT# #UNINDENT# else : #NEWLINE# #INDENT# meanr = np . zeros ( self . model . k_exog_re ) #NEWLINE# #UNINDENT# #UNINDENT# return meanr