Questions tagged as 'python'

1
answer

Doubts files and lists python

I'm starting to program in python, and I've been asked to make a menu that asks the user for the code, name, surname, city and add this to a file. I've been thinking and it comes to mind, create a list where to enter the data entered by the u...
asked by 28.02.2018 / 17:33
1
answer

error 'int' object is not subscriptable

After doing this program I get an error of the following type:    n = 2 * n [i]   TypeError: 'int' object is not subscriptable I would like to know what part of the code I have to change. def arquimides(x): n = 6 l = 1 impo...
asked by 25.02.2018 / 12:36
1
answer

Validate a field of type Float accept zeros after a decimal point in SQLAlchemy

I am using the Sqlalchemy orm, when I enter a data of type Float or Numeric does not accept zeros, example: price = 12.0231 price = 12.1021 price = 12.0012 The previous ones, if you keep the zeros The problem is when the z...
asked by 25.02.2018 / 01:17
1
answer

pyodbc remote server connection

Dear, I am working on a database in ms access I make a query locally and everything works well with the module pyodbc I leave the syntax: conn = pyodbc.connect("Driver={Microsoft Access Driver (*.mdb, *.accdb)};DBQ=C:\Users\Doron E\Desktop\...
asked by 01.03.2018 / 18:13
0
answers

Menu in window without borders

You will see I have this code to generate a program without borders in PyQt5 the problem is in the menu bar. The first thing I tried was to directly load the main menu with the menuBar () function, but I can not accommodate the close, minimiz...
asked by 01.03.2018 / 18:29
1
answer

Get json values

I have this json { "type": "FeatureCollection", "features": [ { "id": "0", "type": "Feature", "properties": { "Name": "L�nea G - Buenos Aires - Tapiales", "L...
asked by 23.02.2018 / 11:44
1
answer

Key Error creating a nested dictionary within IF statement

I am running a piece of code that does not present any problem to me when executing it out of the if sentence but when entering it to the sentence it throws me: Traceback (most recent call last): if self.genero in self.DiccionarioRe...
asked by 20.02.2018 / 21:36
1
answer

Trading Indicators

My question would be, assuming I have precio1 precio2 precio3 precio4 precio5 precio6 precio7 precio8 precio9 precio10 precio11 precio12 precio13 precio14 How would the function to remove rsi, bollinger band, macd, etc.?     
asked by 22.02.2018 / 23:43
1
answer

the code must read a file type .txt and put it in cipher cease, the problem is that it takes away the spaces

r=2 while r==2: print("1. Cifrar \n") print("2. Decifrar\n") res = pos=int(input("Elige una opcion de las anteriores \n =>")) ar = open ('prueba.txt','r') #archivo que lee G = ar.read() print(G)# imprime texto que exi...
asked by 22.02.2018 / 21:15
0
answers

PyQt5 apply QgraphicsBlurEffect.performancehint and change the position of the DropShadow effect

Good evening. I am working on an application with PyQt. A colleague shared the following instruction self.shadow.BlurHint(QGraphicsBlurEffect.PerformanceHint) . This is to improve the performance of the application when executing the...
asked by 13.03.2018 / 05:53