workflow

How to rename files with snakemake with a dictionary in config file?

How to rename files with snakemake with a dictionary in config file? Question: I currently have the issue of renaming some files with snakemake based on pattern matching with help of a dictionary in the config file. The input wildcard does not match the output wildcard any more afterwards. The data follow this structure: . …

Total answers: 1

Snakemake | Creating an aggregate without specifying a list in expand

Snakemake | Creating an aggregate without specifying a list in expand Question: My directory structure looks like this: — path — parameter_combination_1 – time_average.property1.csv – time_average.property2.csv – … — parameter_combination_2 – time_average.property1.csv – time_average.property2.csv – … — … I would like to create a rule which aggregates information of all files which carry the time_average …

Total answers: 2

Exiting Python Debugger ipdb

Exiting Python Debugger ipdb Question: I use ipdb fairly often in a way to just jump to a piece of code that is isolated i.e. it is hard to write a real script that uses it. Instead I write a minimal test case with mocking and jump into it. Exemplary for the workflow: def func(): …

Total answers: 6

Importing an ipynb file from another ipynb file?

Importing an ipynb file from another ipynb file? Question: Interactive Python (ipython) is simply amazing, especially as you are piecing things together on the fly… and does it in such a way that it is easy to go back. However, what seems to be interesting is the use-case of having multiple ipython notebooks (ipynb files). …

Total answers: 11

Importing modules in Python – best practice

Importing modules in Python – best practice Question: I am new to Python as I want to expand skills that I learned using R. In R I tend to load a bunch of libraries, sometimes resulting in function name conflicts. What is best practice in Python. I have seen some specific variations that I do …

Total answers: 6