Skip to content

Instantly share code, notes, and snippets.

View popen.py
with subprocess.Popen(
cmd,
stdout=subprocess.PIPE,
stderr=subprocess.PIPE,
shell=True,
text=True
) as p:
p.wait()
if p.returncode != 0:
View generator.py
def group_snp():
for gene, grp in itt.groupby(gene_snps_grp, key=lambda x: x['gene']):
if gene in gene_lenghts:
yield gene, len(list(grp)) * 1000 / gene_lenghts[gene]
# possibilité 1: création de dictinnaire à partir d'un générateur de tuple2
gene_snp_rate = dict(group_snp())
View keybase.md

Keybase proof

I hereby claim:

  • I am max-l on github.
  • I am maxxou (https://keybase.io/maxxou) on keybase.
  • I have a public key ASAYH2EmCIrKnllCDZ9VLy38xpGw9GMZL4OYUY88KvduGgo

To claim this, I am signing this object:

@max-l
max-l / .block
Last active Dec 15, 2018
Enter+Update merge
View .block
license: mit
@max-l
max-l / .block
Last active Dec 15, 2018
fresh block
View .block
license: mit
@max-l
max-l / .block
Last active Dec 13, 2018
select and grouping
View .block
license: mit
View .block
license: mit
View .block
license: mit
View .block
license: mit
View .block
license: mit