- Overview
- Why Python for Data Science?
- Project Structure
- Getting Started
- Learning Modules
- Sample Code Examples
- Working with Sample Data
- Dependencies
- Contributing
- Next Steps
This is a comprehensive Python learning project featuring interactive Jupyter notebooks that cover fundamental Python programming concepts with a focus on data science applications. The project is organized into modular sections, each focusing on specific Python topics with hands-on exercises and practical examples.
- Python Basics: Data types, control structures, and core programming concepts
- Functions: Basic and advanced function concepts, parameters, and scope
- Object-Oriented Programming: Classes, inheritance, polymorphism, and magic methods
- Data Structures: Lists, dictionaries, collections, and nested data structures
- File Management: Reading/writing files, CSV handling, and HTTP operations
- Database Operations: PostgreSQL integration and database APIs
- Data Serialization: JSON and XML processing
- Exception Handling: Custom exceptions and error management
- NumPy: Numerical computing and array operations
- Pandas: Data analysis and manipulation
- Matplotlib: Data visualization and plotting
- Standard Library: Built-in Python modules and utilities
Data Science combines programming, statistics, and domain expertise to extract insights from data. Python is one of the most popular languages for data science due to:
- Easy to learn: Simple, readable syntax that's perfect for beginners
- Extensive libraries: NumPy, Pandas, Matplotlib, Scikit-learn, and many more
- Community support: Large community with extensive documentation and tutorials
- Versatility: Can handle data collection, processing, analysis, and deployment
- Integration: Works well with other tools and languages
ine/
├── README.md # Project documentation
├── introduction/ # Python basics and fundamentals
│ ├── list.ipynb # Lists and list operations
│ ├── Dictionaries.ipynb # Dictionary data structures
│ └── Loops.ipynb # For/while loops and iteration
├── function/ # Function concepts
│ ├── Basic.ipynb # Basic function syntax and usage
│ └── Advanced_Function.ipynb # Advanced function concepts
├── object-oriented-programming/ # OOP concepts
│ ├── Introduction.ipynb # OOP basics
│ ├── Atrributes.ipynb # Class attributes
│ ├── Method.ipynb # Class methods
│ ├── Inheritance.ipynb # Inheritance concepts
│ ├── Polymorphism.ipynb # Polymorphism examples
│ ├── Super_and_Overriding.ipynb # Method overriding
│ ├── Magic_Methods.ipynb # Special methods
│ └── Getattr_Setattr_Hasattr.ipynb # Attribute manipulation
├── collection/ # Advanced data structures
│ └── Nested Collections.ipynb # Working with nested collections
├── file-management-and-http/ # File and web operations
│ ├── Intro to File Management.ipynb
│ ├── Intro to Files (Cheatsheet).ipynb
│ ├── Writing_Files.ipynb
│ ├── The with context manager.ipynb
│ ├── CSV Old School.ipynb
│ ├── HTTP Practice.ipynb
│ ├── alice.txt # Sample text file
│ └── products.csv # Sample CSV data
├── database/ # Database operations
│ └── pg/ # PostgreSQL examples
│ ├── DB-API.ipynb
│ ├── Adapters.ipynb
│ ├── Admin-Tools.ipynb
│ └── DDL.ipynb
├── serialization/ # Data serialization
│ ├── Data - Serialization.ipynb # JSON serialization
│ ├── XML - Serialization.ipynb # XML processing
│ └── data/ # Sample data files
│ ├── data.json
│ ├── movie.csv
│ ├── movie.txt
│ └── quran.xml
├── exceptions/ # Error handling
│ └── Custom Exceptions.ipynb # Custom exception classes
├── numpy/ # Numerical computing
│ └── Introduction.ipynb # NumPy arrays and operations
├── pandas/ # Data analysis and manipulation
│ ├── introduction.ipynb # Getting started with pandas
│ ├── Analys.ipynb # Data analysis examples
│ ├── Plot_Analsis.ipynb # Data visualization with pandas
│ └── data/
│ ├── bestsellers.csv # Amazon bestsellers dataset
│ ├── cars.csv # Car data for analysis
│ └── invoices.csv # Sample invoice data
├── Matplotlib/ # Data visualization
│ └── introduction.ipynb # Plotting and visualization basics
├── module/ # Python modules
│ └── modules.py # Module examples
└── standard_library/ # Python standard library usage
- Python 3.7+ installed on your system
- Jupyter Notebook or JupyterLab
- Basic understanding of programming concepts (helpful but not required)
-
Clone the repository
git clone <repository-url> cd ine
-
Create a virtual environment (recommended)
# Using conda (recommended for data science) conda create -n python-fundamentals python=3.9 conda activate python-fundamentals # Or using venv python -m venv python-fundamentals source python-fundamentals/bin/activate # On Windows: python-fundamentals\Scripts\activate
-
Install required packages
# Using conda (recommended) conda install jupyter pandas matplotlib seaborn numpy psycopg2 requests # Or using pip pip install jupyter pandas matplotlib seaborn numpy psycopg2-binary requests
-
Launch Jupyter Notebook
jupyter notebook # or jupyter lab
Begin with the introduction/ folder to learn Python basics:
- Lists: Understanding list data structures and operations
- Dictionaries: Key-value pairs and dictionary methods
- Loops: Iteration and control flow
Explore function/ to understand:
- Basic function syntax and parameters
- Advanced concepts like *args, **kwargs
- Scope and local/global variables
The object-oriented-programming/ section covers:
- Class creation and instantiation
- Attributes and methods
- Inheritance and polymorphism
- Special methods (magic methods)
Learn advanced data manipulation:
- Collections: Working with nested data structures
- File Management: Reading and writing files
- Serialization: JSON and XML processing
Dive into numerical computing and data science:
- NumPy: Array operations and numerical computing
- Pandas: Data manipulation, analysis, and cleaning
- Matplotlib: Creating plots and visualizations
- Database Operations: PostgreSQL integration with DB-API
- Exception Handling: Custom error management
- HTTP Operations: Web requests and APIs
- Standard Library: Built-in Python modules
- Start with
introduction/- Python basics (lists, dictionaries, loops) - Progress to
function/- Function concepts and advanced features - Move to
object-oriented-programming/- OOP principles and implementation - Explore
collection/- Advanced data structures - Practice with
file-management-and-http/- File operations and web requests - Learn
numpy/- Numerical computing fundamentals - Advance to
pandas/- Data analysis and manipulation - Visualize with
Matplotlib/- Creating plots and charts - Experiment with specialized topics - databases, serialization, exceptions
# Data types and control structures
numbers = [1, 2, 3, 4, 5]
student = {"name": "Alice", "age": 25, "grades": [85, 90, 88]}
# List comprehension
even_squares = [x**2 for x in range(10) if x % 2 == 0]
# Functions with flexible arguments
def my_function(*args, **kwargs):
print("Args: {}".format(args))
print("Kwargs: {}".format(kwargs))
my_function(2, 'a', hello=True, goodbye=None)import numpy as np
# Creating arrays and basic operations
arr = np.array([1, 2, 3, 4, 5])
matrix = np.array([[1, 2, 3], [4, 5, 6]])
random_data = np.random.normal(0, 1, 1000)import pandas as pd
# Load and explore data
df = pd.read_csv('data/bestsellers.csv')
print("Shape:", df.shape)
print("Columns:", df.columns.tolist())
# Data visualization
df.plot(kind='scatter', x='Reviews', y='Price', figsize=(12, 6))import matplotlib.pyplot as plt
# Create plots
x = np.linspace(0, 10, 100)
y = np.sin(x)
plt.figure(figsize=(10, 6))
plt.plot(x, y)
plt.title('Sine Wave')
plt.xlabel('x')
plt.ylabel('sin(x)')
plt.grid(True)
plt.show()The project includes various sample datasets for hands-on practice:
pandas/data/bestsellers.csv- Amazon bestsellers for analysis practicepandas/data/cars.csv- Car data for basic operationspandas/data/invoices.csv- Invoice data for business analyticsfile-management-and-http/products.csv- Product data for file operationsfile-management-and-http/alice.txt- Text file for reading exercisesserialization/data/- Various formats (JSON, CSV, XML) for serialization practice
- Navigate to the desired module folder
- Open the corresponding
.ipynbfile in Jupyter - Run cells sequentially using
Shift + Enter - Complete exercises and experiment with the code
- Modify examples to test your understanding
jupyter>=1.0.0
pandas>=1.3.0
matplotlib>=3.5.0
seaborn>=0.11.0
numpy>=1.21.0
psycopg2-binary>=2.9.0
requests>=2.25.0
This is a learning project, but contributions are welcome! Here's how you can help:
- Fork the repository
- Create a new branch for your feature
- Add new notebooks following the existing structure
- Include clear explanations and practical examples
- Test all code cells to ensure they run without errors
- Submit a pull request with a description of your additions
- Fix typos or unclear explanations
- Add more examples or exercises
- Improve code comments and documentation
- Suggest better learning progressions
- Add more sample datasets
- Keep notebooks focused on specific topics
- Include markdown cells with clear explanations
- Provide practical, runnable examples
- Add sample data when helpful
- Follow consistent naming conventions
- Ensure code works with the specified dependencies
After completing this fundamental course, consider exploring:
- Decorators and context managers
- Generators and iterators
- Asyncio and concurrent programming
- Testing with pytest
- Package development and distribution
- Advanced pandas operations (groupby, pivot tables, time series)
- Statistical analysis with SciPy
- Machine learning with Scikit-learn
- Deep learning with TensorFlow or PyTorch
- Data visualization with Plotly and Bokeh
- Flask or Django frameworks
- REST API development
- Database design and management
- Frontend integration with JavaScript
- Financial analysis and quantitative finance
- Bioinformatics and computational biology
- Image processing with OpenCV
- Natural language processing with NLTK/spaCy
- Automation and scripting
- Python.org Documentation
- Real Python Tutorials
- Kaggle Learn - For data science
- NumPy Documentation
- Pandas Documentation
- Matplotlib Tutorials
Happy Learning! 🐍
Remember: Programming is best learned by doing. Don't just read the code—run it, modify it, and experiment with it. Each notebook is designed to be interactive, so make the most of the hands-on exercises!