Python Forum
Search Results
Post Author Forum Replies Views Posted [asc]
    Thread: For Loop, over even index
Post: For Loop, over even index

I've created a code to combine pages of a pdf. The code will combine every two pages together. The issue is when the index is odd, it will not display the last page. Any tips on how to fix this? f...
shaynehansen General Coding Help 2 3,491 Jul-24-2017, 06:09 PM
    Thread: Pdf merging
Post: RE: Pdf merging

If anyone is wondering the solution. I figured out by using mergeTranslatedPage() function, and by setting the mediaBox() function large enough to fit both of my pdf pages.
shaynehansen General Coding Help 2 3,211 Jul-21-2017, 05:16 PM
    Thread: Pdf merging
Post: Pdf merging

I am trying to make my pdf appear as page 1 being the upper half of first page, and page 2 being the lower half of first page and so on. Currently my code just moves page 2 onto page 1 completely ov...
shaynehansen General Coding Help 2 3,211 Jul-20-2017, 03:23 PM
    Thread: IndexError: index out of bounds for axis 1
Post: IndexError: index out of bounds for axis 1

Getting the error: return self._RDMS_data[0:, channel_index] IndexError: index 840 is out of bounds for axis 1 with size 840 The class RDMSDictionary is where the data is read in, and class Pdfs is...
shaynehansen General Coding Help 0 9,318 Jul-13-2017, 10:49 PM
    Thread: Adding text to plots
Post: Adding text to plots

I am trying to add text to my plots in the upper right of the plot. The issue is the plots vertical axis is constantly changing. Is there a way to lock the text to the same spot regardless of the axis...
shaynehansen General Coding Help 0 3,333 Jul-10-2017, 05:54 PM
    Thread: Reduce code run time
Post: RE: Reduce code run time

Larz you are totally right. The file read in through the looping was the issue. Thank you very much!
shaynehansen Data Science 2 3,313 Jul-07-2017, 09:54 PM
    Thread: Reduce code run time
Post: Reduce code run time

Hey guys, I'm trying to run a few files through a loop, but the run time is way to high. I am wondering if there is an issue with the way I coded it, that could cut down the time it takes to run the f...
shaynehansen Data Science 2 3,313 Jul-07-2017, 09:34 PM
    Thread: How to append arrays within a class
Post: RE: How to append arrays within a class

_keys is a list. _arr and _time are numpy arrays.
shaynehansen Data Science 3 3,696 Jun-28-2017, 07:57 PM
    Thread: How to append arrays within a class
Post: How to append arrays within a class

Essentially the class will act as a dictionary. I need to append the string 'Time' to the self._keys list. Also, I have a (32768, 1233) self._arr. I want to append a (32768, ) self._time to the self...
shaynehansen Data Science 3 3,696 Jun-28-2017, 06:51 PM
    Thread: dictionary construction help
Post: dictionary construction help

I'm trying to assign my values to my keys. The issue is the 2D array, it is only reading in by rows, and I need it to by columns. I want to be able to use the special methods class i created as well. ...
shaynehansen Data Science 1 34,014 Jun-26-2017, 04:15 PM
    Thread: Need help reading in a binary file
Post: Need help reading in a binary file

I need help figuring out how to read in a binary file, and then placing it into a numpy array. The error I am getting is: AttributeError: 'ReadBinary' object has no attribute 'array' Thank you in ...
shaynehansen Data Science 2 3,962 Jun-21-2017, 10:49 PM
    Thread: Help using class methods
Post: Help using class methods

I have setup the class methods I would like to use instead of the code below the class. I am new to classes and still learning, how to make them work effectively. Any help or tips would be greatly a...
shaynehansen Data Science 1 2,939 Jun-19-2017, 10:46 PM

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020