if ind == 0:
for j in range (c_source-1,f_source):
place.iloc[j,0]=place.iloc[j,0]+1
legenda = pd.DataFrame([lado_source])
place = pd.concat((legenda, place), join='outer')
if ind == 1:
for k in range (c_source-1,f_source):
place1.iat[k,0]=place1.iat[k,0]+1
legenda = pd.DataFrame([lado_source])
place1 = pd.concat((legenda, place1), join='outer')
if ind == 2:
for j in range (c_source-1,f_source):
place2.iloc[j,0]=place2.iloc[j,0]+1
legenda = pd.DataFrame([lado_source])
place2 = pd.concat((legenda, place2), join='outer')
if ind == 3:
for j in range (c_source-1,f_source):
place3.iloc[j,0]=place3.iloc[j,0]+1
legenda = pd.DataFrame([lado_source])
place3 = pd.concat((legenda, place3), join='outer')
Hello everyone! I'm looking to produce a program that identifies a case (ind), with this case identifies limits (c_source and f_source) and with these limits produces an array. This statement works well for the first case (if ind == 0), but when it arrives in the second case, at the time of producing the array, I get the message "IndexError: index 1 is out of bounds for axis 0 with size 1"
I suppose this means that I'm trying to access an array dimension that does not exist, but I'm trying to mark it in the first column of it.
Thank you for your attention!