<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="de">
	<id>https://staging.moocwiki.org/index.php?action=history&amp;feed=atom&amp;title=English%3AData_Science_with_Python</id>
	<title>English:Data Science with Python - Versionsgeschichte</title>
	<link rel="self" type="application/atom+xml" href="https://staging.moocwiki.org/index.php?action=history&amp;feed=atom&amp;title=English%3AData_Science_with_Python"/>
	<link rel="alternate" type="text/html" href="https://staging.moocwiki.org/index.php?title=English:Data_Science_with_Python&amp;action=history"/>
	<updated>2026-08-30T00:38:30Z</updated>
	<subtitle>Versionsgeschichte dieser Seite in MOOCsWiki Staging</subtitle>
	<generator>MediaWiki 1.45.4</generator>
	<entry>
		<id>https://staging.moocwiki.org/index.php?title=English:Data_Science_with_Python&amp;diff=47967&amp;oldid=prev</id>
		<title>Glanz: aiMOOC über GPT aiMOOC Action erstellt</title>
		<link rel="alternate" type="text/html" href="https://staging.moocwiki.org/index.php?title=English:Data_Science_with_Python&amp;diff=47967&amp;oldid=prev"/>
		<updated>2026-08-29T12:26:26Z</updated>

		<summary type="html">&lt;p&gt;aiMOOC über GPT aiMOOC Action erstellt&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Neue Seite&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{T}}&lt;br /&gt;
[[Category:English]]&lt;br /&gt;
[[Category:Data Science with Python]]&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
= Introduction =&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Data Science with Python&amp;#039;&amp;#039;&amp;#039; is a course for Grades 11–13 that shows you how to turn a question into evidence using data, computation, statistics, and careful communication. You will learn how to inspect datasets, clean them, explore patterns, build simple predictive models, evaluate results, and discuss ethical limits. The goal is not only to make code run, but to understand what the code means and when a conclusion is justified.&lt;br /&gt;
&lt;br /&gt;
[[File:Python-logo-notext.svg|250px|frameless|center]]&lt;br /&gt;
&lt;br /&gt;
Data science combines ideas from [[English:Computer science|Computer science]], [[English:Statistics|Statistics]], [[English:Mathematics|Mathematics]], and subject knowledge. Python is widely used because it has a clear syntax and a large ecosystem for scientific computing, data analysis, visualization, and machine learning. In this course, you will use tools such as [[English:Python programming language|Python]], [[English:Jupyter|Jupyter]], [[English:NumPy|NumPy]], [[English:Pandas|Pandas]], [[English:Matplotlib|Matplotlib]], and [[English:Scikit-learn|Scikit-learn]].&lt;br /&gt;
&lt;br /&gt;
{{#ev:youtube|https://www.youtube.com/watch?v=LHBE6Q9XlzI|500|center}}&lt;br /&gt;
&lt;br /&gt;
By the end of the course, you should be able to explain a data-science workflow, write and read short Python programs, analyze tabular data with pandas, create informative visualizations, use descriptive statistics, train and evaluate a simple model, recognize common sources of bias, and communicate results with appropriate uncertainty.&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
== What You Need Before You Start ==&lt;br /&gt;
&lt;br /&gt;
You should be comfortable with basic arithmetic, percentages, graphs, and algebra. Previous programming experience is useful but not required. A browser-based notebook environment or a local Python installation can be used. When you work with real data, keep a record of the source, units, variable definitions, collection method, and any changes you make.&lt;br /&gt;
&lt;br /&gt;
[[File:Jupyter logo.svg|180px|frameless|center]]&lt;br /&gt;
&lt;br /&gt;
A [[English:Jupyter Notebook|Jupyter Notebook]] mixes executable code, text, formulas, tables, and charts in one document. This makes notebooks useful for data science because your reasoning can sit next to the calculations that support it.&lt;br /&gt;
&lt;br /&gt;
{{#ev:youtube|https://www.youtube.com/watch?v=HW29067qVWk|500|center}}&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
= From a Question to Evidence =&lt;br /&gt;
&lt;br /&gt;
A useful data-science project starts with a question that can be answered with evidence. A strong question identifies what you want to measure, which population or system you care about, and what decision or explanation the analysis should support.&lt;br /&gt;
&lt;br /&gt;
A typical workflow is:&lt;br /&gt;
&lt;br /&gt;
# [[English:Research question|Research question]]: State a focused question and define the quantities or categories you need.&lt;br /&gt;
# [[English:Data collection|Data collection]]: Obtain data from a trustworthy source or design a fair collection process.&lt;br /&gt;
# [[English:Data cleaning|Data cleaning]]: Check structure, types, missing values, duplicates, impossible values, and inconsistent labels.&lt;br /&gt;
# [[English:Exploratory data analysis|Exploratory data analysis]]: Use summaries and visualizations to understand distributions, relationships, and unusual cases.&lt;br /&gt;
# [[English:Statistical model|Statistical model]]: Build a model only when it helps answer the question or make a prediction.&lt;br /&gt;
# [[English:Model evaluation|Model evaluation]]: Test performance on data that were not used to fit the model.&lt;br /&gt;
# [[English:Data visualization|Communication]]: Explain the result, uncertainty, assumptions, limitations, and possible consequences.&lt;br /&gt;
&lt;br /&gt;
The workflow is iterative. A chart may reveal a data problem, an evaluation may reveal that your features are weak, or a new question may require additional data. Reproducible work keeps these revisions visible rather than hiding them.&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
== Data, Observations, Variables, and Targets ==&lt;br /&gt;
&lt;br /&gt;
A &amp;#039;&amp;#039;&amp;#039;dataset&amp;#039;&amp;#039;&amp;#039; is a structured collection of observations. In a typical table, each row represents an observation and each column represents a variable. A variable may be numerical, categorical, Boolean, text, date-time, or another structured type. A &amp;#039;&amp;#039;&amp;#039;feature&amp;#039;&amp;#039;&amp;#039; is an input variable used by an analysis or model. A &amp;#039;&amp;#039;&amp;#039;target&amp;#039;&amp;#039;&amp;#039; is the outcome a predictive model tries to estimate.&lt;br /&gt;
&lt;br /&gt;
Before calculating anything, ask what each row represents. A row might represent a student, a weather station, a transaction, a city, or a measurement event. Misunderstanding the unit of observation can produce incorrect conclusions even when the code is technically correct.&lt;br /&gt;
&lt;br /&gt;
Create a small &amp;#039;&amp;#039;&amp;#039;data dictionary&amp;#039;&amp;#039;&amp;#039; that records the variable name, meaning, data type, unit, allowed range or categories, and whether missing values are possible. This simple habit prevents many errors later.&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
= The Python Data-Science Toolkit =&lt;br /&gt;
&lt;br /&gt;
Python itself provides variables, expressions, conditionals, loops, functions, modules, and data structures such as lists and dictionaries. Data science adds specialized libraries.&lt;br /&gt;
&lt;br /&gt;
[[File:NumPy logo 2020.svg|450px|frameless|center]]&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;NumPy&amp;#039;&amp;#039;&amp;#039; provides fast multidimensional arrays and numerical operations. Many scientific Python libraries build on NumPy arrays.&lt;br /&gt;
&lt;br /&gt;
[[File:Pandas logo.svg|450px|frameless|center]]&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;pandas&amp;#039;&amp;#039;&amp;#039; provides the Series and DataFrame structures. A DataFrame behaves like a labeled table and supports selection, filtering, grouping, reshaping, merging, and handling missing data.&lt;br /&gt;
&lt;br /&gt;
[[File:Matplotlib icon.svg|180px|frameless|center]]&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Matplotlib&amp;#039;&amp;#039;&amp;#039; creates plots such as line graphs, bar charts, histograms, scatter plots, and more specialized visualizations.&lt;br /&gt;
&lt;br /&gt;
[[File:Scikit learn logo small.svg|400px|frameless|center]]&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;scikit-learn&amp;#039;&amp;#039;&amp;#039; provides consistent tools for preprocessing, model training, evaluation, and many standard machine-learning algorithms.&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
== A First Python Data Analysis ==&lt;br /&gt;
&lt;br /&gt;
Suppose a CSV file contains columns named score, study_hours, and course. The following example loads the file, inspects it, calculates a summary, and groups the data.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;python&amp;quot;&amp;gt;&lt;br /&gt;
import pandas as pd&lt;br /&gt;
&lt;br /&gt;
df = pd.read_csv(&amp;quot;students.csv&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
print(df.head())&lt;br /&gt;
df.info()&lt;br /&gt;
&lt;br /&gt;
mean_score = df[&amp;quot;score&amp;quot;].mean()&lt;br /&gt;
scores_by_course = df.groupby(&amp;quot;course&amp;quot;)[&amp;quot;score&amp;quot;].mean()&lt;br /&gt;
&lt;br /&gt;
print(mean_score)&lt;br /&gt;
print(scores_by_course)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The expression &amp;lt;code&amp;gt;df[&amp;quot;score&amp;quot;]&amp;lt;/code&amp;gt; selects one column. The method &amp;lt;code&amp;gt;mean()&amp;lt;/code&amp;gt; calculates its arithmetic mean. The &amp;lt;code&amp;gt;groupby()&amp;lt;/code&amp;gt; operation separates rows by course and then computes a mean for each group. A useful analysis always connects such outputs back to the original question.&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
= Working with DataFrames =&lt;br /&gt;
&lt;br /&gt;
A DataFrame is central to many Python data-analysis tasks. You should be able to inspect its size, column names, data types, and missing values before doing advanced calculations.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;python&amp;quot;&amp;gt;&lt;br /&gt;
print(df.shape)&lt;br /&gt;
print(df.columns)&lt;br /&gt;
print(df.dtypes)&lt;br /&gt;
print(df.isna().sum())&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Selection chooses relevant rows or columns. Filtering keeps only rows that meet a condition.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;python&amp;quot;&amp;gt;&lt;br /&gt;
selected = df[[&amp;quot;study_hours&amp;quot;, &amp;quot;score&amp;quot;]]&lt;br /&gt;
high_scores = df[df[&amp;quot;score&amp;quot;] &amp;gt;= 80]&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can also create derived variables. For example, if a dataset contains distance in meters and time in seconds, a speed variable can be calculated from those two columns. Derived variables should have clear names and units.&lt;br /&gt;
&lt;br /&gt;
Grouping and aggregation help compare categories.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;python&amp;quot;&amp;gt;&lt;br /&gt;
summary = (&lt;br /&gt;
    df.groupby(&amp;quot;course&amp;quot;)[&amp;quot;score&amp;quot;]&lt;br /&gt;
      .agg([&amp;quot;count&amp;quot;, &amp;quot;mean&amp;quot;, &amp;quot;median&amp;quot;])&lt;br /&gt;
      .sort_values(&amp;quot;mean&amp;quot;, ascending=False)&lt;br /&gt;
)&lt;br /&gt;
print(summary)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{#ev:youtube|https://www.youtube.com/watch?v=ZyhVh-qRZPA|500|center}}&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
= Cleaning and Preparing Data =&lt;br /&gt;
&lt;br /&gt;
Real datasets often contain missing values, duplicates, inconsistent spelling, mixed data types, impossible values, or measurements recorded in different units. Cleaning is not a cosmetic step. It changes the evidence on which later conclusions depend.&lt;br /&gt;
&lt;br /&gt;
Use a repeatable process:&lt;br /&gt;
&lt;br /&gt;
# [[English:Missing data|Missing data]]: Determine why values are missing before deciding whether to keep, remove, or replace them.&lt;br /&gt;
# [[English:Duplicate data|Duplicate data]]: Check whether repeated rows are genuine repeated events or accidental copies.&lt;br /&gt;
# [[English:Data type|Data type]]: Convert numbers, dates, and categories to appropriate types before calculation.&lt;br /&gt;
# [[English:Outlier|Outlier]]: Investigate unusual observations rather than deleting them automatically.&lt;br /&gt;
# [[English:Unit of measurement|Unit of measurement]]: Standardize units before combining or comparing values.&lt;br /&gt;
# [[English:Data validation|Data validation]]: Test rules such as allowed ranges, required columns, and category labels.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;python&amp;quot;&amp;gt;&lt;br /&gt;
df = df.drop_duplicates()&lt;br /&gt;
df[&amp;quot;score&amp;quot;] = pd.to_numeric(df[&amp;quot;score&amp;quot;], errors=&amp;quot;coerce&amp;quot;)&lt;br /&gt;
df[&amp;quot;course&amp;quot;] = df[&amp;quot;course&amp;quot;].str.strip().str.title()&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The argument &amp;lt;code&amp;gt;errors=&amp;quot;coerce&amp;quot;&amp;lt;/code&amp;gt; converts values that cannot be interpreted as numbers into missing values. That can be useful, but you still need to inspect which values were affected and why.&lt;br /&gt;
&lt;br /&gt;
[[File:Box plot.svg|500px|frameless|center]]&lt;br /&gt;
&lt;br /&gt;
A box plot summarizes a distribution using its median, quartiles, and a rule for marking points beyond the whiskers. A point beyond a whisker is not automatically an error. It may be a valid extreme observation that deserves investigation.&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
= Exploring and Visualizing Data =&lt;br /&gt;
&lt;br /&gt;
Exploratory data analysis helps you understand what is present before you make a formal claim. Use several views because each one emphasizes different information.&lt;br /&gt;
&lt;br /&gt;
A histogram is useful for the distribution of one numerical variable. A bar chart compares counts or summary values across categories. A scatter plot shows the relationship between two numerical variables. A box plot helps compare distributions and identify unusual values. A line graph is useful when an ordered variable such as time is central.&lt;br /&gt;
&lt;br /&gt;
[[File:Iris dataset scatterplot.svg|500px|frameless|center]]&lt;br /&gt;
&lt;br /&gt;
The classic Iris dataset shows how several measured flower features vary across three species. A scatterplot matrix makes it possible to compare pairs of variables and see which measurements provide useful separation between groups.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;python&amp;quot;&amp;gt;&lt;br /&gt;
import matplotlib.pyplot as plt&lt;br /&gt;
&lt;br /&gt;
df.plot.scatter(x=&amp;quot;study_hours&amp;quot;, y=&amp;quot;score&amp;quot;)&lt;br /&gt;
plt.xlabel(&amp;quot;Study hours&amp;quot;)&lt;br /&gt;
plt.ylabel(&amp;quot;Score&amp;quot;)&lt;br /&gt;
plt.title(&amp;quot;Study time and score&amp;quot;)&lt;br /&gt;
plt.show()&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{#ev:youtube|https://www.youtube.com/watch?v=UO98lJQ3QGI|500|center}}&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
== Why You Should Look at the Data ==&lt;br /&gt;
&lt;br /&gt;
Summary statistics can hide important structure. Anscombe&amp;#039;s quartet consists of four datasets with the same common summary statistics and fitted linear relationship, yet their plots look very different.&lt;br /&gt;
&lt;br /&gt;
[[File:Anscombe&amp;#039;s quartet with Matplotlib.svg|500px|frameless|center]]&lt;br /&gt;
&lt;br /&gt;
The lesson is practical: do not rely on a single statistic. Inspect distributions, create visualizations, check assumptions, and investigate influential observations.&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
= Statistics for Data Science =&lt;br /&gt;
&lt;br /&gt;
Descriptive statistics summarize what is in a dataset. The &amp;#039;&amp;#039;&amp;#039;mean&amp;#039;&amp;#039;&amp;#039; uses every value and is sensitive to extremes. The &amp;#039;&amp;#039;&amp;#039;median&amp;#039;&amp;#039;&amp;#039; is the middle value after sorting and is often more robust to extreme observations. The &amp;#039;&amp;#039;&amp;#039;range&amp;#039;&amp;#039;&amp;#039; measures the distance from the minimum to the maximum. The &amp;#039;&amp;#039;&amp;#039;interquartile range&amp;#039;&amp;#039;&amp;#039; describes the middle half of the data. The &amp;#039;&amp;#039;&amp;#039;standard deviation&amp;#039;&amp;#039;&amp;#039; measures typical spread around the mean.&lt;br /&gt;
&lt;br /&gt;
A sample is only part of a larger population or process. When you use sample results to make a broader claim, you must consider how the sample was selected. A large biased sample can still give a misleading answer.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Correlation&amp;#039;&amp;#039;&amp;#039; measures the strength and direction of an association between variables. Correlation does not by itself establish causation. A relationship may be influenced by confounding variables, reverse causation, selection effects, or chance. Causal claims require stronger designs and assumptions than a simple scatter plot.&lt;br /&gt;
&lt;br /&gt;
Uncertainty should be reported when it matters. Repeated samples from the same process would not give exactly the same result. Confidence intervals, resampling, and error bars are tools for describing that variation when their assumptions are appropriate.&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
= Predictive Modeling =&lt;br /&gt;
&lt;br /&gt;
A predictive model learns a relationship between input features and a target from examples. In &amp;#039;&amp;#039;&amp;#039;regression&amp;#039;&amp;#039;&amp;#039;, the target is numerical. In &amp;#039;&amp;#039;&amp;#039;classification&amp;#039;&amp;#039;&amp;#039;, the target is a category. The purpose of evaluation is to estimate how well the model will perform on relevant new cases, not how perfectly it can remember the training data.&lt;br /&gt;
&lt;br /&gt;
A common procedure separates data into training and test sets. The model learns from the training set and is evaluated on the test set. If you repeatedly adjust the model based on the test result, the test set stops being a clean estimate of future performance.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;python&amp;quot;&amp;gt;&lt;br /&gt;
from sklearn.model_selection import train_test_split&lt;br /&gt;
from sklearn.linear_model import LinearRegression&lt;br /&gt;
from sklearn.metrics import mean_absolute_error&lt;br /&gt;
&lt;br /&gt;
X = df[[&amp;quot;study_hours&amp;quot;]]&lt;br /&gt;
y = df[&amp;quot;score&amp;quot;]&lt;br /&gt;
&lt;br /&gt;
X_train, X_test, y_train, y_test = train_test_split(&lt;br /&gt;
    X, y, test_size=0.2, random_state=42&lt;br /&gt;
)&lt;br /&gt;
&lt;br /&gt;
model = LinearRegression()&lt;br /&gt;
model.fit(X_train, y_train)&lt;br /&gt;
&lt;br /&gt;
predictions = model.predict(X_test)&lt;br /&gt;
mae = mean_absolute_error(y_test, predictions)&lt;br /&gt;
&lt;br /&gt;
print(mae)&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Mean absolute error gives the average absolute difference between predictions and true numerical values. For classification, suitable metrics may include accuracy, precision, recall, and the F1 score. The choice depends on the problem and on which kinds of mistakes matter.&lt;br /&gt;
&lt;br /&gt;
A &amp;#039;&amp;#039;&amp;#039;baseline&amp;#039;&amp;#039;&amp;#039; is a simple reference method. A sophisticated model should be compared with a baseline so you can tell whether the additional complexity is useful.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Overfitting&amp;#039;&amp;#039;&amp;#039; occurs when a model captures details or noise in its training data that do not generalize well. Cross-validation repeatedly creates training and validation splits to estimate performance more reliably and can help compare model choices.&lt;br /&gt;
&lt;br /&gt;
{{#ev:youtube|https://www.youtube.com/watch?v=fSytzGwwBVw|500|center}}&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
= Ethics, Privacy, Bias, and Responsible Use =&lt;br /&gt;
&lt;br /&gt;
Data science affects people, so technical correctness is not enough. Ask who is represented in the data, who is missing, how the data were collected, whether consent or legal permission is required, and what harms could result from an error.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Privacy&amp;#039;&amp;#039;&amp;#039; means more than removing names. Combinations of location, time, age, or other attributes can sometimes identify people indirectly. Use only the data you need, restrict access when appropriate, and avoid publishing sensitive individual-level information.&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Bias&amp;#039;&amp;#039;&amp;#039; can enter through sampling, measurement, labels, historical inequalities, missing data, feature selection, or the way a model is deployed. A model can have good average performance while performing poorly for an important subgroup. Compare performance across relevant groups when doing so is lawful, ethical, and statistically meaningful.&lt;br /&gt;
&lt;br /&gt;
A responsible report should state the purpose, data source, important preprocessing choices, evaluation method, limitations, uncertainty, and intended use. It should also identify uses for which the analysis is not reliable.&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
= Reproducibility and Communication =&lt;br /&gt;
&lt;br /&gt;
A reproducible analysis allows another person to understand and rerun the essential steps. Keep raw data separate from cleaned data, write transformations in code rather than making undocumented manual edits, use meaningful variable names, record software requirements, and organize your notebook in the order of your reasoning.&lt;br /&gt;
&lt;br /&gt;
A strong data story has four parts: a clear question, transparent evidence, an interpretation that does not overclaim, and a conclusion that acknowledges limitations. Good visualizations have readable labels, appropriate scales, units, and enough context for the viewer to understand what is being compared.&lt;br /&gt;
&lt;br /&gt;
Before sharing a result, ask whether the chart could mislead because of a truncated axis, unequal group sizes, hidden missing data, inappropriate aggregation, or a color scale that implies more precision than the data support.&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
= A Small End-to-End Example =&lt;br /&gt;
&lt;br /&gt;
Imagine that your school wants to understand whether classroom temperature is associated with student comfort ratings. You could design a short study using room-level measurements and anonymous comfort ratings.&lt;br /&gt;
&lt;br /&gt;
First define the unit of observation, such as one classroom session. Record temperature, time, room identifier, occupancy, and an anonymous comfort score. Then check units, missing measurements, repeated entries, and whether data collection was consistent across rooms. Plot temperature against comfort, compare distributions across rooms or times, and calculate suitable summaries.&lt;br /&gt;
&lt;br /&gt;
A predictive model could be added only if there is a real prediction goal, such as estimating comfort for a future session. Even then, a model does not prove that changing temperature alone will cause a change in comfort. Other factors such as humidity, activity, sunlight, or ventilation may matter.&lt;br /&gt;
&lt;br /&gt;
This example shows the difference between description, prediction, and causation. Data science can support each goal, but the evidence needed for each one is different.&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
= Interactive Tasks =&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
== Quiz: Test Your Knowledge ==&lt;br /&gt;
&lt;br /&gt;
{{MC}}&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What is the main purpose of a test set in predictive modeling?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
(To estimate performance on unseen data)&lt;br /&gt;
(!To increase the number of training rows)&lt;br /&gt;
(!To remove all missing values)&lt;br /&gt;
(!To guarantee a causal conclusion)&lt;br /&gt;
&lt;br /&gt;
{{E}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{MC}}&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Which pandas structure is designed for labeled tabular data?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
(DataFrame)&lt;br /&gt;
(!Dictionary only)&lt;br /&gt;
(!Loop)&lt;br /&gt;
(!Function)&lt;br /&gt;
&lt;br /&gt;
{{E}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{MC}}&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Which graph is especially useful for examining the relationship between two numerical variables?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
(Scatter plot)&lt;br /&gt;
(!Pie chart)&lt;br /&gt;
(!Single value table)&lt;br /&gt;
(!Word cloud)&lt;br /&gt;
&lt;br /&gt;
{{E}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{MC}}&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What should you do first when you find an extreme value?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
(Investigate its meaning and source)&lt;br /&gt;
(!Delete it automatically)&lt;br /&gt;
(!Replace it with zero)&lt;br /&gt;
(!Hide it from every graph)&lt;br /&gt;
&lt;br /&gt;
{{E}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{MC}}&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What does correlation by itself establish?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
(Association)&lt;br /&gt;
(!Causation)&lt;br /&gt;
(!Random assignment)&lt;br /&gt;
(!Perfect prediction)&lt;br /&gt;
&lt;br /&gt;
{{E}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{MC}}&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Why is a baseline model useful?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
(It provides a reference for judging improvement)&lt;br /&gt;
(!It guarantees the best possible model)&lt;br /&gt;
(!It removes the need for testing)&lt;br /&gt;
(!It converts every target into a category)&lt;br /&gt;
&lt;br /&gt;
{{E}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{MC}}&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What is overfitting?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
(Learning training details that do not generalize well)&lt;br /&gt;
(!Using too few column names)&lt;br /&gt;
(!Drawing more than one chart)&lt;br /&gt;
(!Saving data in a CSV file)&lt;br /&gt;
&lt;br /&gt;
{{E}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{MC}}&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Which measure is usually more robust to extreme numerical values?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
(Median)&lt;br /&gt;
(!Mean)&lt;br /&gt;
(!Maximum)&lt;br /&gt;
(!Range)&lt;br /&gt;
&lt;br /&gt;
{{E}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{MC}}&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;What does reproducibility require?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
(A clear record of data and analysis steps)&lt;br /&gt;
(!A hidden sequence of manual edits)&lt;br /&gt;
(!A chart without labels)&lt;br /&gt;
(!A model with no documented settings)&lt;br /&gt;
&lt;br /&gt;
{{E}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{MC}}&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Which practice best supports responsible data science?&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
(Report limitations and important sources of bias)&lt;br /&gt;
(!Assume more data always remove bias)&lt;br /&gt;
(!Publish sensitive personal data)&lt;br /&gt;
(!Treat every prediction as a causal explanation)&lt;br /&gt;
&lt;br /&gt;
{{E}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
== Memory Game ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;memo-quiz&amp;quot;&amp;gt;&lt;br /&gt;
{|&lt;br /&gt;
|-&lt;br /&gt;
| DataFrame || Labeled two-dimensional table used for data analysis&lt;br /&gt;
|-&lt;br /&gt;
| Feature || Input variable used by a model&lt;br /&gt;
|-&lt;br /&gt;
| Target || Outcome that a predictive model tries to estimate&lt;br /&gt;
|-&lt;br /&gt;
| Median || Middle value after numerical observations are sorted&lt;br /&gt;
|-&lt;br /&gt;
| Outlier || Observation that lies unusually far from most others&lt;br /&gt;
|-&lt;br /&gt;
| Overfitting || Learning training-specific patterns that generalize poorly&lt;br /&gt;
|-&lt;br /&gt;
| Cross-validation || Repeated split-based evaluation used to compare model choices&lt;br /&gt;
|}&lt;br /&gt;
{{E}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
== Drag and Drop ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;lueckentext-quiz&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Match the correct terms.&lt;br /&gt;
! Topic&lt;br /&gt;
|-&lt;br /&gt;
| &amp;#039;&amp;#039;&amp;#039;State the question and outcome&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
| Problem definition&lt;br /&gt;
|-&lt;br /&gt;
| &amp;#039;&amp;#039;&amp;#039;Check missing and inconsistent values&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
| Data cleaning&lt;br /&gt;
|-&lt;br /&gt;
| &amp;#039;&amp;#039;&amp;#039;Plot distributions and relationships&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
| Exploratory analysis&lt;br /&gt;
|-&lt;br /&gt;
| &amp;#039;&amp;#039;&amp;#039;Fit a predictive relationship&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
| Model training&lt;br /&gt;
|-&lt;br /&gt;
| &amp;#039;&amp;#039;&amp;#039;Measure performance on held-out cases&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
| Model evaluation&lt;br /&gt;
|}&lt;br /&gt;
{{E}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
...&lt;br /&gt;
&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
== Crossword Puzzle ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;kreuzwort-quiz&amp;quot;&amp;gt;&lt;br /&gt;
{|&lt;br /&gt;
|-&lt;br /&gt;
| Python || Which programming language is used throughout this course?&lt;br /&gt;
|-&lt;br /&gt;
| Pandas || Which library provides the DataFrame structure?&lt;br /&gt;
|-&lt;br /&gt;
| Median || Which statistic is the middle value after sorting?&lt;br /&gt;
|-&lt;br /&gt;
| Outlier || What do you call an unusually extreme observation?&lt;br /&gt;
|-&lt;br /&gt;
| Regression || Which modeling task predicts a numerical target?&lt;br /&gt;
|-&lt;br /&gt;
| Validation || What process checks whether a model performs well beyond its training examples?&lt;br /&gt;
|}&lt;br /&gt;
{{E}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
== LearningApps ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;iframe&amp;gt; https://learningapps.org/index.php?s=Data+Science+with+Python &amp;lt;/iframe&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
== Cloze Text ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;quiz display=simple&amp;gt;&lt;br /&gt;
{&amp;#039;&amp;#039;&amp;#039;Complete the text.&amp;#039;&amp;#039;&amp;#039;&amp;lt;br&amp;gt;&lt;br /&gt;
|type=&amp;quot;{}&amp;quot;}&lt;br /&gt;
A data-science project should begin with a focused { question }. A pandas { DataFrame } stores labeled tabular data. Cleaning includes checking missing values, duplicates, types, and possible { outliers }. A scatter plot can reveal an { association } between two numerical variables. The middle value of sorted observations is the { median }. A predictive model should be tested on data it did not use for { training }. Learning training-specific noise that performs poorly on new cases is called { overfitting }. Responsible analysis reports uncertainty, limitations, and possible sources of { bias }.&lt;br /&gt;
&amp;lt;/quiz&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
= Open-Ended Tasks =&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
=== Easy ===&lt;br /&gt;
# [[English:Dataset diary|Dataset diary]]: Choose a small public dataset and write a one-page data diary that identifies the source, unit of observation, variables, units, missing-value codes, and one question you could investigate.&lt;br /&gt;
# [[English:Data types audit|Data types audit]]: Import a CSV file into pandas, inspect its column types, and produce a short annotated table showing which types are appropriate and which should be changed.&lt;br /&gt;
# [[English:Visualization makeover|Visualization makeover]]: Find or create a weak chart, redesign it with clearer labels, scales, and visual choices, then explain in 150 words why your revision communicates the evidence better.&lt;br /&gt;
# [[English:Reproducible notebook|Reproducible notebook]]: Create a Jupyter notebook that loads a small dataset, shows the first rows, calculates two summaries, and includes clear Markdown explanations so another learner can rerun it.&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
=== Standard ===&lt;br /&gt;
# [[English:Missing data investigation|Missing data investigation]]: Introduce or locate missing values in a dataset, compare at least two reasonable handling strategies, and write a short report explaining how each strategy changes the result.&lt;br /&gt;
# [[English:Group comparison study|Group comparison study]]: Collect or use public data for two or more groups, create suitable plots and descriptive statistics, and explain what can and cannot be concluded from the comparison.&lt;br /&gt;
# [[English:Correlation critique|Correlation critique]]: Identify a pair of correlated variables in a dataset, visualize the relationship, propose at least two possible confounding factors, and write a paragraph that avoids causal overclaiming.&lt;br /&gt;
# [[English:Interview a data practitioner|Interview a data practitioner]]: Interview a person who uses data in science, business, government, journalism, or another field, then summarize their workflow, quality checks, ethical concerns, and one skill they consider essential.&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
=== Advanced ===&lt;br /&gt;
# [[English:Prediction pipeline|Prediction pipeline]]: Build a complete regression or classification notebook with preprocessing, a baseline, a train-test split, one model, an appropriate metric, and a written interpretation of the result.&lt;br /&gt;
# [[English:Bias audit|Bias audit]]: Examine a dataset or model for possible representation, measurement, or label bias, compare outcomes across relevant subgroups when appropriate, and propose concrete risk-reduction steps.&lt;br /&gt;
# [[English:Public data story|Public data story]]: Use an open-government or scientific dataset to produce a short data story with at least three coordinated visualizations, a methods note, a limitations section, and a clear audience.&lt;br /&gt;
# [[English:Model comparison video|Model comparison video]]: Compare two simple machine-learning methods with cross-validation, create a three-to-five-minute explanatory video showing the evidence, and justify which model you would choose for the stated purpose.&lt;br /&gt;
&lt;br /&gt;
{{:Open Task - Create a MOOC}}&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
= Learning Assessment =&lt;br /&gt;
&lt;br /&gt;
# [[English:Transfer analysis|Transfer analysis]]: Given an unfamiliar dataset, formulate a defensible question, identify the unit of observation and variable types, and justify a complete analysis plan before writing code.&lt;br /&gt;
# [[English:Cleaning decision|Cleaning decision]]: Analyze a dataset with missing values, duplicates, and extreme observations, defend each cleaning decision, and explain how alternative choices could change the conclusion.&lt;br /&gt;
# [[English:Visualization reasoning|Visualization reasoning]]: Select an appropriate visualization for a stated question, explain why it is preferable to two alternatives, and identify at least one way the chart could still mislead.&lt;br /&gt;
# [[English:Model evaluation|Model evaluation]]: Compare a baseline with a fitted model using a suitable metric, interpret the size and practical meaning of the difference, and diagnose one plausible source of poor generalization.&lt;br /&gt;
# [[English:Ethical case study|Ethical case study]]: Evaluate a proposed use of student or community data, identify privacy and bias risks, and recommend safeguards that preserve useful analysis while reducing harm.&lt;br /&gt;
# [[English:Communication challenge|Communication challenge]]: Produce a concise report for a nontechnical audience that distinguishes observed evidence, prediction, uncertainty, and causal claims without hiding important limitations.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
= Evidence of Learning =&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Knowledge:&amp;#039;&amp;#039;&amp;#039; You can explain core concepts including observation, variable, feature, target, distribution, missing data, correlation, baseline, train-test split, overfitting, evaluation metric, bias, and reproducibility.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Skills:&amp;#039;&amp;#039;&amp;#039; You can load, inspect, clean, transform, group, summarize, and visualize data with Python; fit and evaluate a simple model; and interpret outputs in context.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Products:&amp;#039;&amp;#039;&amp;#039; Your evidence may include a reproducible notebook, data dictionary, cleaned dataset, annotated visualizations, model-evaluation table, written report, presentation, interview summary, or explanatory video.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;Transfer:&amp;#039;&amp;#039;&amp;#039; You can apply the workflow to an unfamiliar dataset, choose methods that fit a new question, recognize when evidence is insufficient, and communicate limitations responsibly.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
= OERs on the Topic =&lt;br /&gt;
&lt;br /&gt;
&amp;lt;iframe&amp;gt; https://en.m.wikipedia.org/wiki/Data_science &amp;lt;/iframe&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Useful open learning resources include the [https://docs.python.org/3/tutorial/ Python Tutorial], the [https://pandas.pydata.org/docs/getting_started/intro_tutorials/ pandas Getting Started Tutorials], [https://numpy.org/learn/ NumPy Learn], the [https://matplotlib.org/stable/tutorials/index.html Matplotlib tutorials], and the [https://scikit-learn.org/stable/getting_started.html scikit-learn Getting Started guide].&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
= Linked Learning Areas =&lt;br /&gt;
&lt;br /&gt;
{| align=center&lt;br /&gt;
{{:D-Tab}}&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;[[English:Data Science with Python|Data Science with Python]]&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
# [[English:Python programming|Python programming]]&lt;br /&gt;
# [[English:Data analysis|Data analysis]]&lt;br /&gt;
# [[English:Data visualization|Data visualization]]&lt;br /&gt;
# [[English:Statistics|Statistics]]&lt;br /&gt;
# [[English:Probability|Probability]]&lt;br /&gt;
# [[English:Machine learning|Machine learning]]&lt;br /&gt;
# [[English:Research methods|Research methods]]&lt;br /&gt;
# [[English:Data ethics|Data ethics]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{{BR}}&lt;br /&gt;
= aiMOOC Projects =&lt;br /&gt;
[[Category:English]]&lt;br /&gt;
[[Category:Data Science with Python]]&lt;br /&gt;
[[Category:Computer science]]&lt;br /&gt;
[[Category:Data science]]&lt;br /&gt;
[[Category:Python]]&lt;br /&gt;
[[Category:Statistics]]&lt;br /&gt;
[[Category:Mathematics]]&lt;br /&gt;
[[Category:Machine learning]]&lt;br /&gt;
[[Category:Data visualization]]&lt;br /&gt;
[[Category:Grades 11-13]]&lt;br /&gt;
[[Category:AI_MOOC]]&lt;br /&gt;
[[Category:GPT aiMOOC]]&lt;br /&gt;
{{MT}}&lt;/div&gt;</summary>
		<author><name>Glanz</name></author>
	</entry>
</feed>