Logistic Regression

  1. Survival Prediction By Logistic Regression

    Question 1 of 1

    • Train and Predict titanic patient survival using Logistic Regression. 1. Load titanic dataset titanic.csv as a pandas DataFrame. 2. Preprocess: Handle Missing values, Duplicates, Datatype & Other Data Issues. 3. Encoding: Use StandardScaler, OrdinalEncoder, NominalEncoder to encode features. 4. Combine Encoded Features. 5. Split dataset into training and testing (75% train, 25% test). 6. Train LogisticRegression using training data for different penalty and C values. 7. Tuning Model: Find best hyperparameters and accuracy value for it. 8. Predict: Make predictions on the titanic_predict.csv data. 9. Using titanic_result.csv, determine accuracy of the model on prediction data.