Module 1 · Start Here: Think Like a Data Scientist · Lesson 3 of 51

Your toolkit, your first code, and data ethics

How the in-browser Python works, notebooks and the tools you'll meet at work, your first lines of code, and the ethical rules every data scientist follows.

In this lesson · about 30 minutes

  • Run and edit a Python cell, and solve a checked exercise
  • Name the everyday tools: Jupyter, VS Code, Google Colab, Git
  • Explain personal data, consent and bias in plain words

How the code boxes work

  • Code cells are examples. The value of the last line is shown underneath, the way a Jupyter notebook does. Charts appear as pictures.
  • Exercises have a task, a starter and a Check button. Your code runs and is compared with a model answer. Stuck? Open the hint, or reveal the solution and type it out yourself.
  • The first run takes a few seconds while Python loads; after that it is quick.
  • The café data files (orders, daily sales, members, an A/B test) are copied in for you, so pd.read_csv("kc_orders.csv") just works.

The tools you will meet at work

ToolWhat it is for
Jupyter notebooksCode, results, charts and notes in one document. The standard for exploring data.
Google ColabFree Jupyter notebooks in the browser, with nothing to install.
VS CodeA code editor for scripts and larger projects; it also opens notebooks.
Anaconda or pipWays to install Python and its libraries on your own computer.
Git and GitHubTrack changes to your code and share your portfolio.
A SQL clientRun queries against the company database (often built into tools like DBeaver or the warehouse's web page).

Your first cell

Press Run. Then change the numbers and run it again.

A peek at what's coming

Three lines of pandas read 4,420 café orders and total them by branch. By Module 5 you'll write this yourself.

Exercise

Weekend revenue

On Saturday the café sold 180 muffins at 3.00 each and 240 lattes at 4.50 each. Store the total revenue in a variable called revenue.

Data ethics: the rules that come with the job

Data is often about people, and data scientists are trusted with it. Four rules to live by:

  1. Protect personal data. Names, emails, phone numbers, addresses, card numbers and precise locations are personally identifiable information (PII). Use the least you need, never paste it into public tools, and remove or mask it (for example, replace names with member IDs) before analysis. Laws such as the EU's GDPR and California's CCPA give people rights over their data, with real fines for misuse.
  2. Respect consent and purpose. Data collected to run loyalty points should not quietly be used for something else people would not expect.
  3. Look for bias. If past data reflects unfair decisions, a model trained on it learns them. A hiring model trained on a company that rarely hired women will rate women lower. Always ask who is missing from the data and who could be harmed by a wrong prediction.
  4. Be honest about uncertainty. Report what the data supports, not what the boss hopes. Don't hunt through dozens of comparisons until one looks "significant" (you'll see why in Module 9).

Decision scenario

The marketing request

You are the café chain's only data scientist.

The marketing lead asks you to export the full member list, with names, emails, birthdays and every order, into a shared spreadsheet so an outside agency can "find insights". The agency has not signed any data agreement.

What do you recommend?

0 of 3 options explored. Try the others to see how each would play out.

Flashcards

Module 1 flashcards

0 of 8 known

Say the answer out loud, flip the card, then be honest: cards you miss come back at the end.

8 left in the deck

Practice exam

Module 1 checkpoint

8 questions, 10 minutes. Aim for 80% before moving on.

  • 8 questions · 10 minutes
  • No feedback until you submit. Flag questions to come back to them.
  • Aim for 85% or better before you move on. The real exam's 750 out of 900 is roughly 80–83%.

Exercises solved: 0 of 1

Tip: solve each exercise first. Press Check to test your code.

Written by Noviq Academy in its own words. Kettle & Crumb and all its data are made up for teaching; any resemblance to a real business is a coincidence. Python runs in your browser with Pyodide, so results can differ slightly from your own computer. Power BI, Tableau and other product names belong to their owners. Read-aloud uses your device's built-in voices.