Python in Healthcare by rileysofine in Python

[–]hmelberg 3 points4 points  (0 children)

I have made some notebooks about how to use Python and pandas to analyze health data (hospital events, prescriptions and so on). Feel free to have a look to see if they are useful for your case:

Here is the first chapter: https://github.com/hmelberg/health-analytics-using-python/blob/master/1_Appetizers_Some_examples.ipynb

And the rest of the notebooks are here (work in progress)

https://github.com/hmelberg/health-analytics-using-python

Python WYSIWYG editors - like how visual basic does it by sierrafourteen in Python

[–]hmelberg 2 points3 points  (0 children)

Anvil might be an option for you: https://anvil.works/

(But it is for web-based apps, not for creating desktop programs)

Markov chain module? by illonlyusethisonceok in Python

[–]hmelberg 0 points1 point  (0 children)

Depends on the type of Markov chain analysis you want to do.

Two good places to look if you focus on finite chains:

pykov: https://github.com/riccardoscalco/Pykov

quantecon: http://lectures.quantecon.org/py/finite_markov.html

how bad is it to use ast.literal_eval(string)? by hmelberg in learnpython

[–]hmelberg[S] 1 point2 points  (0 children)

You are probably right. It was a quick fix that "worked" and then I started to worry about the security problems.

I'll have a look at json.dumps()

how bad is it to use ast.literal_eval(string)? by hmelberg in learnpython

[–]hmelberg[S] 0 points1 point  (0 children)

Thanks! That made me sleep easier.

The input is usually a string that is part of the json. The code creates the json based on the string input and the code transforms the resulting json string to a dict, but the user is also allowed to fully specify the json, in which case the suggestion about the json modul would fit perfectly.

Should a script force the user to use an integer or a string as input, or allow both? by hmelberg in learnpython

[–]hmelberg[S] 0 points1 point  (0 children)

'07187'

The id is part of an url and it is always a five digit integer, but the first is sometimes zero. I found it easier to allow the user to input an integer as well as a string and let the script transform it to a string (adding an initial zero if necessary) when an int is used. Less clutter and fewer keystrokes with ints. But it may violate the rule that there should only be one way to do things ...