<jupyter_start><jupyter_text>DataFrame  Creating a Pandas DataFrameIn the real world, a Pandas DataFrame will be created by loading the datasets from existing storage, storage can be SQL Database, CSV file, and Excel file. Pandas DataFrame can be created from the lists, dictionary, and from a list of dictionary etc. Dataframe can be created in different ways here are some ways by which we create a dataframe<jupyter_code>import pandas as pd
import numpy as np
# https://www.geeksforgeeks.org/python-pandas-dataframe/<jupyter_output><empty_output><jupyter_text>Create Dataframe From List<jupyter_code>lst = ['one', 'Two', np.nan, 'Four', 5, 'six']

df = pd.DataFrame(lst)
df<jupyter_output><empty_output><jupyter_text>Create Dataframe From Dict<jupyter_code># dictionary of lists 
data = {
        'Name':['Jai', 'Princi', 'Gaurav', 'Anuj'],
        'Age':[27, 24, 22, 32],
        'Address':['Delhi', 'Kanpur', 'Allahabad', 'Kannauj'],
        'Qualification':['Msc', 'MA', 'MCA', 'Phd']
       }
  
df = pd.DataFrame(data,index=data['Name']) # To indicate one column as index
print(df)
df = pd.DataFrame(data) # Auto indexing
df<jupyter_output>Name  Age    Address Qualification
Jai        Jai   27      Delhi           Msc
Princi  Princi   24     Kanpur            MA
Gaurav  Gaurav   22  Allahabad           MCA
Anuj      Anuj   32    Kannauj           Phd<jupyter_text>Dealing With Row ColumnA Data frame is a two-dimensional data structure, i.e., data is aligned in a tabular fashion in rows and columns. We can perform basic operations on rows/columns like selecting, deleting, adding, and renaming.   Column SelectionIn Order to select a column in Pandas DataFrame, we can either access the columns by calling them by their columns name.<jupyter_code>print(df[['Name','Age']]) # To select multiple column.
print('\n\n')
print(df['Age']) # to select only one column.<jupyter_output>Name  Age
0     Jai   27
1  Princi   24
2  Gaurav   22
3    Anuj   32



0    27
1    24
2    22
3    32
Name: Age, dtype: int64
{'fraction_non_alphanumeric': 0.09559187716691431, 'fraction_numerical': 0.02129767211490837, 'mean_word_length': 3.6436781609195403, 'pattern_counts': {'":': 0, '<': 15, '<?xml version=': 0, '>': 15, 'https://': 1, 'lorem ipsum': 0, 'www.': 1, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '4', 'dir': 'jupyter-structured-clean-dedup', 'id': '470884', 'license': 'MIT', 'n_tokens_mistral': 684, 'n_tokens_neox': 648, 'n_words': 238, 'path': 'Data_Analysis/dataframe.ipynb', 'repo_name': 'sharif-42/All_About_DS', 'size': '2019'}