Git Product home page Git Product logo

center-for-health-data-science / pythontsunami Goto Github PK

View Code? Open in Web Editor NEW

This project forked from pythontsunami/teaching

14.0 14.0 11.0 102.4 MB

An introductory course to Python by the Center of Health Data Science (University of Copenhagen)

Home Page: https://center-for-health-data-science.github.io/PythonTsunami/

License: MIT License

Jupyter Notebook 100.00%
beginner course python

pythontsunami's People

Contributors

ajk-dev avatar albsantosdel avatar arcolaco avatar daplaci avatar enryh avatar gero1999 avatar hezscha avatar iprada avatar joseale2310 avatar katnastou avatar marilenahohmann avatar pdcharles avatar thildebt avatar tooche avatar valesora avatar viktoriaschuster avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

pythontsunami's Issues

matplotlib

Request was to add x-axis labels in plain matplotlib in the section "Combining Matplolib, Pandas and Seaborn".

There is already an example for the seaborn plot using matplotlib.axes.Axes.set_xticklabels

To add:

_ = ax.set_xticks(ticks=x)
_ = ax.set_xticklabels(labels=list(some_counts["Denmark"].keys()), rotation=45)
# _ = plt.xticks(ticks=x, labels=list(some_counts["Denmark"].keys()), rotation=45)

Documenting methods - obj.method or obj.method()

Should we document object methods or module functions using obj.method (module.function) or obj.method() (module.function()).

I prefer the former, Rita used the ladder.

notatin arguments
obj.method
module.function
as function are object itself (first-class citizens), they can be assigned. They are callable (or callable()!) which describes them.
obj.method()
module.function()
Suggests directly that they are callable and distinguishes them from other attributes.

I have seen both in the official documentation. I just think it will be good to be consistent.

Any opinion or good reference to elaborate the issue?

Intuitive information

I believe it could be intuitive for health (data) researchers if lists and arrays and so on contains some kind of biological information, so that it is easier to understand/imagine what it could be used for.

For example in the Numpy exercise:

now: values = [4, 9, 1, 0, 8, 3, 2, 2, 6, 5, 0]
suggestion: amino_acids = ['A','C','H','L','R',...]

So exercise "Exercise 2: Access items", could be about removing essential amino acids or something like that?

Description of Hackathon datasets

I tried to find the origins of the vaccines dataset, I guess it is from here

  • Would be maybe good to have an external ressource with updates and description for each, I guess...

Questions on lists

Collection of questions on list

  • inplace manipulation using most list methods. How to copy a list?

Code-Snippets

## List copies

a = 40
another_list = [6, 4, 1, 2, 5, a]
list2 = list(another_list) #.copy()
another_list.sort()

print(another_list)
print(list2)




## Nested list copies

# create a list
inner_list = [40, 50, 60]


outer_list = [6, 4, 1, 2, 5, inner_list]
copy_outer_list = list(outer_list) #.copy()
# copy_outer_list = outer_list.copy()

print(outer_list)
print(copy_outer_list)


inner_list[2] = 500
outer_list[1] = 100
print(outer_list)
print(copy_outer_list)

Formatting

The part about formatting (variables_data-types) could be made simpler by only including one or at least not the depreciated way.

"The old way => % operator (deprecated)"

Datastructures

The python introduction (notebooks prefixed with 1_) does not introduce dictionaries (dicts), tuples or sets. It introduces the list type extensively. As both pandas and scikit-learn at least partly use or return dicts (and one exercise of numpy gets easier with dicts), I would suggest to add a brief, final notebook in the intro part introducting dicts.

The list.ipynb could be complemented with a distinction between lists and tuples.

plotly plots in nbviewer

Checking some details, I visualized the latest plotly notebook. The plotly plots are rendered... I wasn't aware of that.

Could be added as a hint to the README.md

check yourself

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.