https://github.com/asmi-va/college_placement_predictor
Science Score: 13.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
○CITATION.cff file
-
✓codemeta.json file
Found codemeta.json file -
○.zenodo.json file
-
○DOI references
-
○Academic publication links
-
○Academic email domains
-
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (10.7%) to scientific vocabulary
Repository
Basic Info
- Host: GitHub
- Owner: Asmi-va
- Language: Jupyter Notebook
- Default Branch: main
- Size: 5.84 MB
Statistics
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
- Releases: 0
Metadata Files
README.md
College Placement Prediction
Overview
This project involves predicting college placement outcomes using machine learning algorithms. The dataset, collegePlace.csv, includes various features related to students and their placement status. The goal is to build and evaluate classification models to predict whether a student will be placed based on their features.
Features
- Gender: Gender of the student.
- Stream: Academic stream of the student.
- Age: Age of the student (commented out in the code).
- Hostel: Hostel status of the student (commented out in the code).
- PlacedOrNot: Target variable indicating whether the student has been placed (1) or not (0).
Installation
Dependencies
- Python 3.x
- Pandas
- NumPy
- Matplotlib
- Seaborn
- Scikit-learn
Setup
Clone the Repository
bash git clone https://github.com/yourusername/college-placement-prediction.git cd college-placement-predictionInstall Required Packages
It is recommended to use a virtual environment:
bash python -m venv venv source venv/bin/activate # On Windows use `venv\Scripts\activate`Install the necessary packages:
bash pip install pandas numpy matplotlib seaborn scikit-learnDownload the Dataset
Ensure the dataset
collegePlace.csvis in the project directory.
Usage
Load and Explore the Data
```python import pandas as pd import numpy as np import matplotlib.pyplot as plt import seaborn as sns %matplotlib inline
df = pd.read_csv('collegePlace.csv') df.shape df.head() df.describe() df.info() df.isnull().sum() ```
Preprocess the Data
```python from sklearn import preprocessing
le = preprocessing.LabelEncoder() df['Gender'] = le.fittransform(df['Gender']) df['Stream'] = le.fittransform(df['Stream']) ```
Visualize the Data
python sns.pairplot(df) tc = df.corr() sns.heatmap(tc)Prepare Data for Modeling
python x = df.drop(columns=['PlacedOrNot', 'Hostel']) y = df['PlacedOrNot']Split the Data
```python from sklearn.modelselection import traintest_split
xtrain, xtest, ytrain, ytest = traintestsplit(x, y, testsize=0.3, randomstate=3) ```
Train and Evaluate Models
Decision Tree Classifier
```python from sklearn.tree import DecisionTreeClassifier from sklearn import metrics
clf = DecisionTreeClassifier() clf = clf.fit(xtrain, ytrain) ypred = clf.predict(xtest)
cm = metrics.confusionmatrix(ytest, ypred) acc = metrics.accuracyscore(ytest, ypred) pre = metrics.precisionscore(ytest, ypred) re = metrics.recallscore(ytest, ypred) f1 = metrics.f1score(ytest, y_pred) ```
Random Forest Classifier
```python from sklearn.ensemble import RandomForestClassifier
classifier = RandomForestClassifier(nestimators=1000) classifier.fit(xtrain, ytrain) ypredrf = classifier.predict(xtest)
cmrf = confusionmatrix(ytest, ypredrf) accrf = metrics.accuracyscore(ytest, ypredrf) prerf = metrics.precisionscore(ytest, ypred_rf) ```
Results
Decision Tree Classifier:
- Accuracy:
acc - Precision:
pre - Recall:
re - F1 Score:
f1
- Accuracy:
Random Forest Classifier:
- Accuracy:
acc_rf - Precision:
pre_rf
- Accuracy:
Contributing
Contributions are welcome! Please fork the repository and submit a pull request with your changes. Ensure that your code adheres to the project's coding standards and includes appropriate tests.
License
This project is licensed under the MIT License. See the LICENSE file for details.
Acknowledgements
- Scikit-learn
- Pandas
- Matplotlib
- Seaborn
Owner
- Name: asmi
- Login: Asmi-va
- Kind: user
- Repositories: 1
- Profile: https://github.com/Asmi-va