lib/redred.py
def exportCSV_old(self, directory):
        """
        save rrScan() to a file. it overwrites anything it finds

        Metadata is obtained from get_metadata(), resulting in all non0
        parameters available.
            """

        file = open(directory + self.filename + '.txt', 'w+')

        # Material:
        file.write('Material:\t' + str(self.material) + '\n')
        # Date:
        file.write('Date:\t' + self.date + '\n')
        # Parameters
        file.write('------- Parameters -------\n\n')
        for key in self.parameters:
            if self.parameters[key][0] != 0:
                file.write(key + '\t' +
                           str(self.parameters[key][0]) + '\t' +
                           str(self.parameters[key][1]) + '\n' )
        #filter info
        if self.filter:
            file.write('\nLow pass filter frequency:\t' +
                       str(self.filter) +'\t' +
                       str(self.filterFreq()) +
                       'THz\n')
        #data
        file.write('---------- Data ----------\n\n')
        file.write('Time\tRawData\tdata\n')
        for i in range(len(self.trace)):
            file.write(str(self.time[i])     + ',' +
                       str(self.rawtrace[i]) + ',' +
                       str(self.trace[i])    + '\n')
            self.time = np.array(self.time)
        file.close()

        save rrScan() to a file. it overwrites anything it finds

        Metadata is obtained from get_metadata(), resulting in all non0
        parameters available.
            
save rrScan() to a file. it overwrites anything it finds
Metadata is obtained from get_metadata(), resulting in all non0
parameters available.
save rrScan () to a file . it overwrites anything it finds Metadata is obtained from get_metadata () resulting in all non0 parameters available .
def exportCSV_old(self, directory):
        file = open(directory + self.filename + '.txt', 'w+')
        file.write('Material:\t' + str(self.material) + '\n')
        file.write('Date:\t' + self.date + '\n')
        file.write('------- Parameters -------\n\n')
        for key in self.parameters:
            if self.parameters[key][0] != 0:
                file.write(key + '\t' +
                           str(self.parameters[key][0]) + '\t' +
                           str(self.parameters[key][1]) + '\n' )
        if self.filter:
            file.write('\nLow pass filter frequency:\t' +
                       str(self.filter) +'\t' +
                       str(self.filterFreq()) +
                       'THz\n')
        file.write('---------- Data ----------\n\n')
        file.write('Time\tRawData\tdata\n')
        for i in range(len(self.trace)):
            file.write(str(self.time[i])     + ',' +
                       str(self.rawtrace[i]) + ',' +
                       str(self.trace[i])    + '\n')
            self.time = np.array(self.time)
        file.close()
def exportCSV_old ( self , directory ) : file = open ( directory + self . filename + '.txt' , 'w+' ) file . write ( 'Material:\t' + str ( self . material ) + '\n' ) file . write ( 'Date:\t' + self . date + '\n' ) file . write ( '------- Parameters -------\n\n' ) for key in self . parameters : if self . parameters [ key ] [ 0 ] != 0 : file . write ( key + '\t' + str ( self . parameters [ key ] [ 0 ] ) + '\t' + str ( self . parameters [ key ] [ 1 ] ) + '\n' ) if self . filter : file . write ( '\nLow pass filter frequency:\t' + str ( self . filter ) + '\t' + str ( self . filterFreq ( ) ) + 'THz\n' ) file . write ( '---------- Data ----------\n\n' ) file . write ( 'Time\tRawData\tdata\n' ) for i in range ( len ( self . trace ) ) : file . write ( str ( self . time [ i ] ) + ',' + str ( self . rawtrace [ i ] ) + ',' + str ( self . trace [ i ] ) + '\n' ) self . time = np . array ( self . time ) file . close ( )
save rrScan() to a file.
save rrScan () to a file .
"""
        save rrScan() to a file. it overwrites anything it finds

        Metadata is obtained from get_metadata(), resulting in all non0
        parameters available.
            """ # Material: # Date: # Parameters #filter info #data
self
directory