title: ValueError: Found input variables with inconsistent numbers of samples: [1, 700]
body: <p>I'm performing Linear Regression on the data provided by kaggle on Titanic Survivor prediction .Im trying to predict the list of survivors so iam keep getting this error even after i reshape the Y it still shows this error.</p>
  <pre><code>from sklearn.linear_model import LogisticRegression
  from csv import reader
  import numpy as np
  
  file = open('train.csv', &quot;r&quot;)
  lines = reader(file)
  X = list(lines)
  #Deleting unnecessary features
  X=np.delete(X, (0), axis=0)
  X=np.delete(X, (0), axis=1)
  X=np.delete(X, (2), axis=1)
  X=np.delete(X, (3), axis=1)
  X=np.delete(X, (5), axis=1)
  X=np.delete(X, (5), axis=1)
  X=np.delete(X, (5), axis=1)
  X=np.delete(X, (5), axis=1)
  #Converting males to 1 and females to 0
  for i in range(891):
     if X[i][2]== 'male':
         X[i][2]=1
     else:
         X[i][2]=0
  Y=X.T[0]
  #Converting strings to float
  X1 = X.astype(np.float) 
  Y1 = Y.astype(np.float)
  Xw=X1.reshape(-1,1)
  split = 700
  train,test = Xw[:split,:],Xw[split:,:]
  Ytrain,Ytest = Y1[:split],Y1[:split]
  logisticRegr = LogisticRegression()
  logisticRegr.fit(train.T, Ytrain)
  logisticRegr.predict(test[0].T.reshape(1,-1))
  score = logisticRegr.score(test.T, Ytest)
  </code></pre>