# NCR Course Module 2 ## Class 3 Lesson Plan ## Data Transformation and Visualization [(Recording)](https://t.me/ResearchWG/129/4488) >Register for the class [here](https://near.social/research-collective.near/widget/NCR.v1)! **Facilitator**: [Chloe](https://near.social/mob.near/widget/MyPage?accountId=chloe.near) **Co-Facilitators**: [Nedlar](https://near.social/mob.near/widget/ProfilePage?accountId=15870c8972a9fe6cdb7dfc2df835740108e8674cc170a091cd0ece0b9e4f6cfa) & [BGem](https://near.social/mob.near/widget/ProfilePage?accountId=bheegem.near) **Guest Lecturer**: None **Date**: March 13, 2024 **Time**: 10 AM AST (2 PM UTC) **Duration**: 1 hour **Platform**: [NCR Thread on Telegram](https://t.me/ResearchWG/181) **Target Audience**: - Enthusiasts keen on enhancing blockchain data skills. - Researchers in blockchain applications. - Data analysts seeking blockchain insights. - Computer science students and academics. - NEAR community members seeking technical knowledge. **Learning Objective**: The aim is to familiarize participants with data transformation and visualization techniques using Python and GPT-4. (The case study focuses on EasyPoll data from the Near Protocol.) ### Pre-Reading Material - **Homework and Assignments**: [Homework and Assignment Thread on TG](https://t.me/ResearchWG/1436) - **Course Syllabus**: [NRC Course Syllabus](https://hackmd.io/@doulos819/NRC) - **Introduction to Data Visualization in Python**: [Data Visualization with Python](https://realpython.com/analyzing-obesity-in-england-with-python/) - **GPT-4 Overview**: [What is GPT-4?](https://openai.com/research/gpt-4) - **Python Pandas Documentation**: [Pandas Documentation](https://pandas.pydata.org/docs/) ### Agenda | Time | Topic | Activity | Resource | |-----------|------------------------------|-------------------------------------------------------|------------------------------------------------------| | 0-5 mins | Introduction | Briefing on course outline and objectives. | [ResearchWG on Telegram](https://t.me/ResearchWG/181)| | 5-15 mins | Reading CSV with Pandas | Hands-on Python tutorial for reading CSV files. | [Data Visualization with Python](https://realpython.com/analyzing-obesity-in-england-with-python/) | | 15-25 mins| GPT-4 for Data Analysis | Introduction to using GPT-4 for data interpretation. | [GPT-4 Research Paper](https://openai.com/research/gpt-4)| | 25-40 mins| Lecture from Chloe | How to think about AI x Web3 in practice | [NDC Chatbot](https://ndc-chatbot.nearhub.club/) / [ TG channel for AI summary of NDC chats ](https://t.me/ndcsummaries) / [A.I. Tarot Card Readings](https://tarotbot.app) | | 40-50 mins| Q&A | Open floor for questions. | [Homework and Assignment Thread on TG](https://t.me/ResearchWG/1436) | | 50-55 mins| Summary and Next Steps | Summary of the session and introduction to next lesson.| [Next Class - 4: Advanced Data Evaluation Method With Ai](https://hackmd.io/@doulos819/ncr-04)| ### Activities Details 1. **Python and Pandas Basics** - Brief overview of Python and Pandas for data manipulation. ```python # Import Pandas library import pandas as pd # Create a simple DataFrame df = pd.DataFrame({'A': [1, 2, 3], 'B': ['a', 'b', 'c']}) ``` 2. **Reading CSV with Pandas** - Step-by-step guidance on loading a CSV file into a Pandas DataFrame. ```python # Reading a CSV file into a DataFrame df = pd.read_csv('data.csv') # Display the first 5 rows of the DataFrame df.head() ``` 3. **GPT-4 for Data Analysis** - Exploration of GPT-4's data analysis capabilities. Discuss its utility in data interpretation. 4. **Case Study: EasyPoll** - Practical application focusing on processing and analyzing CSV files from EasyPoll. ```python # Read EasyPoll CSV data df = pd.read_csv('easypoll_data.csv') # Text analysis will be conducted using the GPT-4 UI at this stage. # Visualization (e.g., bar plot of categories) df['category'].value_counts().plot(kind='bar') ```