title: Order of priors in sklearn LinearDiscriminantAnalysis
body: <p>I'm fitting a Linear Discriminant Analysis model using the stock market data (Smarket.csv) from <a href="https://github.com/JWarmenhoven/ISLR-python/tree/master/Notebooks/Data" rel="nofollow noreferrer">here</a>. I'm trying to predict <code>Direction</code> with columns <code>Lag1</code> and <code>Lag2</code>. <code>Direction</code> has two values: <code>Up</code> or <code>Down</code>.</p>
  <p>Here is my reproducible code and the result:</p>
  <pre><code>import pandas as pd
  from sklearn.discriminant_analysis import LinearDiscriminantAnalysis
  
  url=&quot;https://raw.githubusercontent.com/JWarmenhoven/ISLR-python/master/Notebooks/Data/Smarket.csv&quot;
  Smarket=pd.read_csv(url, usecols=range(1,10), index_col=0, parse_dates=True)
  
  X_train = Smarket[:'2004'][['Lag1', 'Lag2']]
  y_train =  Smarket[:'2004']['Direction']
  
  
  LDA = LinearDiscriminantAnalysis()
  model = LDA.fit(X_train, y_train)
  
  print(model.priors_)
  [0.49198397 0.50801603]
  </code></pre>
  <p>How do I know which prior value corresponds to which class (<code>Up</code> or <code>Down</code>)? I looked at the <a href="https://scikit-learn.org/stable/modules/generated/sklearn.discriminant_analysis.LinearDiscriminantAnalysis.html" rel="nofollow noreferrer">documentation</a> but there seems to be nothing.</p>
  <p>Can someone explain it to me or point me to a resource that explains this?</p>