Questions tagged as 'python'

1
answer

Count base frequency in record file

I am looking for ways to improve the following piece of code in such a way that instead of making a total count of the bases of all the records found, it does so by registration. On the other hand I would also like to make it sensitive to one ty...
asked by 29.10.2017 / 20:04
1
answer

Capture KeyboardInterrupt

I'm doing a aplicación cli and I need to capture a KeyboardInterrupt at any point in the execution of the program.    My intention is to delete some folders / files that could have   be generated. Is there any solution cr...
asked by 20.10.2017 / 18:48
1
answer

Selenium python travel dictionary

I am looking to build some function with for in to go through my dictionary. I explain a little the code that I have here, I use selenium. Within Def Name() in variable nametag , I call "NameTag" of my dictionary. So s...
asked by 20.10.2017 / 21:47
1
answer

Counters in files

I have created a function that will be part of a small working script with files but I can not get some characters that I am identifying in this function. By the error messages of the shell I deduce that it is a matter of variables that are not...
asked by 20.10.2017 / 13:39
1
answer

Pandas, selec_index.loc [] same sentence, different results when printing

I do not understand why I get so disparate results presentations with these two sentences that, in principle, are the same (ini = 0 in the script): >>> print (selec_index.loc[0, "Fecha"]) 2017-09-12 00:00:00 >>> print ("Fech...
asked by 12.11.2017 / 21:00
1
answer

how to convert a pdf to jpg

I need to make a program that takes a pdf file that has some data and two graphics and convert it to jpg to insert it into another pdf with additional information or add a second page with the additional information to the pdf. I have been re...
asked by 24.10.2017 / 17:04
1
answer

Separate repeated values from a column in csv Python

I'm wanting to work with a CSV in Python. ID Inventory Domain Requests Impressions Fill Rate 123456 auto neighborhoodscout.com 11402 26 0.23 123456 auto s...
asked by 03.10.2017 / 23:30
2
answers

Problems with Python - syntax

Why do I get an error when inputting a different value of Numbers? Also, why can not I put the "?" even if they are in quotes?     
asked by 27.10.2017 / 23:54
1
answer

Bakcup Django Database

Good afternoon, I have an application in Django 1.10 in which today I need to create a backup of the bd, this copy must be made when the user clicks on a button that will be placed in a template and download the copy on the user's computer. I...
asked by 18.10.2017 / 18:40
1
answer

open a file in Python, asking the name first

Dear, I have a problem, it turns out that I have a code and I want the user to give me the name of the file (including the .txt) and that this can open the file, the point is that to open it you need the quotes , but as this name I keep it insid...
asked by 19.10.2017 / 03:37