FDS Aim Algorithm
FDS Aim Algorithm
AIM:
To download, install and explore the features of Numpy, Scipy,
Jupyter, Statsmodels and pandas packages.
ALGORITHM:
Step 1: Go to Command prompt.
Step 2: Type pip install Numpy.
Step3: Numpy packages have been installed.
Step 4: Type pip Scipy, Scipy packages get installed.
Step 5: Type pip install Jupyter, Jupyter
packages get installed. Step 6: Type pip install
Statsmodel, the packages get installed. Step 7:
Type pip install pandas, the packages get
installed.
RESULT:
Thus the working with commands executed successfully.
EX: NO: 2 WORKING WITH NUMPY ARRAYS
AIM:
Write a python code to implement the concept of Numpy arrays.
ALGORITHM:
AIM:
Write a python code to implement the concept of Pandas Data frames.
ALGORITHM:
Step 1: pandas library
Step 2: Load data into a DataFrame.
Step 3: Explore the DataFrame
Step 4: Selecting data.
Step 5: Manipulating data
Step 6: Cleaning data
Step 7: Saving the modified DataFrame
RESULT:
Thus the working with pandas Data Frame was completed successfully.
EX.No:4
Reading data from text files, Excel and the web and exploring
various commands for doing descriptive analytics on the Iris data set.
AIM:
To Read the data from text files, Excel and the web and exploring various
commands for doing descriptive analytics on the Iris data set.
ALGORITHM:
Step 1: Import the pandas library as pd and the requests library.
Step 2: From the io library, import the BytesIO function.
Step 3: Read data from a text file called iris.txt using the pd.read_csv() function.
Assign the resulting DataFrame to iris_txt. The file has no header row, header=None
is passed as an argument. The column names are specified as a list of strings using the
names argument.
Step 4: Read data from an Excel file called iris.xlsx using the pd.read_excel()
function. Assign the resulting DataFrame to iris_excel.
Step 5: Read data from a CSV file from the web using the requests.get() function to
retrieve the file contents, and then pass the contents to the pd.read_csv() function
using BytesIO to create a file-like object. Assign the resulting DataFrame to iris_web.
The file has no headerrow,so header=None is passed as an argument. The column
names are specified as a list of strings using the names argument.
Step 6: Concatenate the three DataFrames using pd.concat(), and assign the result to
iris. ignore_index=True is passed as an argument to reset the index of the
concatenated DataFrame.
Step 7: Display the descriptive statistics of the entire dataset using iris.describe().
Step 8:Group the data by species and display the mean values for each species using
iris.groupby('species').mean().
Step 9: Create a box plot for each variable by species using iris.boxplot(by='species',
figsize=(10, 8)).
RESULT:
Thus the program was executed successfully.
EX: NO:5a USE THE DIABETES DATA SET FROM UCI AND PIMA
INDIANS DIABETES DATA SET
AIM:
To use the diabetes data set from UCI and Pima Indians diabetes data set
implement Univariate analysis: Frequency, Mean, Median, Mode, Variance, Standard
Deviation, Skewness and Kurtosis from UCI dataset.
ALGORITHM:
Aim:
To perform Bivariate Analysis on diabetes data set from UCI and Pima
Indians Diabetes data set.
Algorithm:
Step1: Download diabetes data set from UCI and Pima Indians
Diabetes data set
Step2: Import necessary Modules and functions
Step3:Read the Dataset path using read_csv().
Step4: Perform Bivariate analysis such as Logistic regression on both the datasets.
RESULT:
Thus the program was executed successfully.
5 c) MULTIPLE REGRESSION ANALYSIS
Aim:
To perform Bivariate Analysis on diabetes data set from UCI and Pima
Indians Diabetes data set.
ALGORITHM:
Step 1: Import Libraries.
Step 2: Import dataset.
Step 3: Define x and y.
Step 4: Train the model on the training set.
Step 5: Predict the test set results.
Step 6: Evaluate the model. Step
7: Plot the results.
RESULT:
Thus the program was executed successfully.
EX: NO: 6 APPLY AND EXPLORE VARIOUS
PLOTTING FUNCTIONS ON UCI DATA SETS
AIM:
To apply and explore various plotting functions on UCI data sets.
a) Normal Curves.
b) Density and Contour Plots.
c) Correlation and Scatter Plots.
d) Histograms.
e) Three Dimensional Plotting.
ALGORITHM:
Step 1: Download diabetes data set from UCI and Pima Indians
Diabetes data set
Link: https://archive.ics.uci.edu/ml/machine-learning-
databases/iris/iris.data"
Step 2: Save that in downloads or any other Folder and install
packages.
Step 3: Apply these following commands on the dataset.
Step 4: The Output will display.
RESULT:
Thus the program was executed successfully.
EX: NO:7 VISUALIZING GEOGRAPHIC DATA WITH BASEMAP
AIM:
To create an insight Geographic Data with Basemap.
ALGORITHM:
Step 1: Install Basemap. The zip file occurs extract the original file.
Step 2: import Packages.
Step3: Save that in downloads or any other Folder.
Step 4: Apply these following commands.
Step 5: The Output will display.
RESULT: