Quant AtlasHomeMarketsAcademyAccount
Quant Atlas · quant-atlas.com
HomeMarketsAcademyAccount
Level I
  1. Academy
  2. Level I
  3. Introductory Python for Research

Level I · Optional · Open anytime

Introductory Python for Research

Start by reading a few lines at a time. Learn what Python objects represent, how a program makes decisions, and how pandas organizes a small research table. Predict each result before revealing it; no installation is needed to use these checks.

Study any section in any order. These checks do not affect your core course or assessments. Choice answers and elective progress are tracked in this browser.

Try six coding tasks with separate solutions

Read the code, predict the result, then check your reasoning. Each example has revealable output. To run or edit the snippets, use your own Python environment.

Optional practice · Browser progress0/4 checks answered
Python elective0% complete
0%

0/2 sections viewed · 0/4 exercises answered

Choose a section · All are open

Section 1 of 2

Read syntax, names, and basic arithmetic

Python executes statements in order. The assignment price = 100 binds the name price to an object representing 100. Names are case-sensitive: Price and price are different. Comments begin with # and describe intent without changing the result.

Integers such as 100 have type int; decimal values such as 0.05 usually have type float. Text uses quotes and has type str. The operators +, − (written as - in code), *, /, and ** mean addition, subtraction, multiplication, division, and exponentiation. Parentheses clarify evaluation order. Use = to assign and == to compare values.

print displays a value. An f-string starts with f before its opening quote and inserts expressions inside braces. The format :.2f displays two decimal places. Formatting changes the displayed text, not the underlying calculation; binary floating-point values can contain tiny representation differences.

Loading the full section…

Translate a familiar calculation

Start with wealth of 100 and a decimal return of 0.05. The expression multiplies wealth by the growth factor. Each name keeps the calculation readable; the percentage convention still has to be correct.

Python example · read it, predict the output, then reveal or run it
wealth = 100
return_rate = 0.05  # 5%, expressed as a fraction
ending_wealth = wealth * (1 + return_rate)
print(f"{ending_wealth:.2f}")
Reveal the expected output
105.00

A closer look

Trace the object types as well as the symbols. 12+3 is integer addition and gives 15. '12'+'3' joins two strings and gives '123'. The expression '12'+3 raises a TypeError rather than silently deciding which meaning you wanted. Convert deliberately with int('12') or str(3) when the input contract calls for that conversion.

Keep in mind: Read each statement as a small operation on named values.

A mistake to avoid

price = 100 assigns a value. price == 100 asks a question and produces True or False. Confusing the two changes the program’s meaning.

Link to this sectionSearchGlossary & formulas ↗

Pause and try two quick checks.

You can move on at any time. Each answer explains the reasoning.

Quick check · Syntax

What does sum([0.1] * 10) == 1.0 return in Python, and what should you use instead?

Quick check · Syntax

What do 7 // 2, -7 // 2 and round(2.5) return?

Further reading and documentation
  • Python tutorial: numbers, text, and lists ↗
  • Python tutorial: data structures ↗
  • Python tutorial: control flow and functions ↗
  • Python reference: objects and mutability ↗
  • pandas: introductory overview ↗
  • pandas: selecting rows and columns ↗
  • pandas: missing data ↗
  • pandas: fractional change ↗
  • pandas: grouping and summary statistics ↗
  • pandas: merging tables ↗
  • pandas: Copy-on-Write and assignment ↗

You are previewing 2 of 13 sections

The full elective is included with Level I enrollment, together with the core course and the official examination.

Enroll in Level I · $9.99All three levels · $24.99Already enrolled? Log in

Go further · Optional resources

Build your mathematics, statistics, and Python toolkit.

Open these resources at any time. They are separate from the core modules and do not count toward examination eligibility, practice scores, or certification. Programming remains optional.

Ready to explore

Mathematical Foundations & Linear Algebra

Build mathematical confidence, then study pure linear algebra with step-by-step examples, geometric interpretation, and quick checks, closing with mental math techniques.

Open the optional resource →

Ready to explore

Introduction to Descriptive Statistics

A compact companion to the core course: calculate medians and modes, compare ranges and quartiles, read empirical percentiles, and build honest frequency summaries.

Open the optional resource →

Ready to explore

Introductory Python for Research

Learn to read basic Python and follow simple pandas workflows, with code examples and instant-feedback checks.

Open the optional resource →