archive-org.com » ORG » C » CHRONUX.ORG

Total: 412

Choose link from "Titles, links and description words view":

Or switch to "Titles and links view".
  • Description of mtpowerandfstatc
    pad if PAD 0 we pad the FFT to 512 points if pad 1 we pad to 1024 points etc Defaults to 0 Fs sampling frequency optional Default 1 f0 frequency of calculation Output P integrated power within the frequency range of interest trapezoidal integration Fstat F statistic f0 frequency CROSS REFERENCE INFORMATION This function calls This function is called by SOURCE CODE 0001 function P Fstat f0 mtpowerandfstatc data params f0 0002 Multi taper computation of the power and the fstatistic for a particular frequency continuous process 0003 0004 Usage 0005 0006 P Fstat f0 mtpowerandfstatc data params f0 0007 Input 0008 Note units have to be consistent See chronux m for more information 0009 data in form samples x channels trials or a single vector required 0010 params structure with fields tapers pad Fs fpass err trialave 0011 optional 0012 tapers precalculated tapers from dpss or in the one of the following 0013 forms 0014 1 A numeric vector TW K where TW is the 0015 time bandwidth product and K is the number of 0016 tapers to be used less than or equal to 0017 2TW 1 0018 2 A numeric vector W T p where W is the 0019 bandwidth T is the duration of the data and p 0020 is an integer such that 2TW p tapers are used In 0021 this form there is no default i e to specify 0022 the bandwidth you have to specify T and p as 0023 well Note that the units of W and T have to be 0024 consistent if W is in Hz T must be in seconds 0025 and vice versa Note that these units must also 0026 be consistent with the units of params Fs W can 0027 be in Hz if and only if params Fs is in Hz 0028 The default is to use form 1 with TW 3 and K 5 0029 0030 pad padding factor for the FFT optional can take values 1 0 1 2 0031 1 corresponds to no padding 0 corresponds to padding 0032 to the next highest power of 2 etc 0033 e g For N 500 if PAD 1 we do not pad if PAD 0 we pad the FFT 0034 to 512 points if pad 1 we pad to 1024 points etc 0035 Defaults to 0 0036 Fs sampling frequency optional Default 1 0037 f0 frequency of calculation 0038 Output 0039 P integrated power within the frequency range of interest trapezoidal integration 0040 Fstat F statistic 0041 f0 frequency 0042 0043 if nargin 1 error Need data end 0044 if nargin 2 params end 0045 tapers pad Fs fpass err trialave params getparams params 0046 clear fpass err trialave params 0047 data change row to column data 0048 N C size data 0049 tapers dpsschk tapers N Fs calculate the tapers 0050 N K size tapers 0051 nfft max 2 nextpow2 N pad N number of points in fft 0052 f0 findx getfgrid Fs

    Original URL path: http://www.chronux.org/Documentation/chronux/spectral_analysis/continuous/mtpowerandfstatc.html (2015-03-27)
    Open archived version from archive


  • Description of spectraMBL2005
    used to evaluate spectrograms 0005 win 2 2 window around events 0006 fignum 2 3 6 9 8 7 4 1 figure numbers for particular directions 0007 for targ 0 7 0008 E targoff find targets targ 0009 Ssp tsp fsp R mtspecgramtrigpt dsp 1 E win movingwin params 0010 figure 1 0011 subplot 3 3 fignum targ 1 0012 imagesc t f 10 log10 S axis xy colorbar 0013

    Original URL path: http://www.chronux.org/Documentation/chronux/old/tutorial/spectraMBL2005.html (2015-03-27)
    Open archived version from archive

  • Description of coherencyc
    trials if trialave 0 dimension frequencies if trialave 1 S2 spectrum 2 frequencies x trials if trialave 0 dimension frequencies if trialave 1 f frequencies confC confidence level for C at 1 p only for err 1 1 phistd theoretical jackknife depending on err 1 1 err 1 2 standard deviation for phi Note that phi 2 phistd and phi 2 phistd will give 95 confidence bands for phi only for err 1 1 Cerr Jackknife error bars for C use only for Jackknife err 1 2 CROSS REFERENCE INFORMATION This function calls mtfftc Multi taper fourier transform continuous data This function is called by coherencysegc Multi taper coherency cross spectrum and individual spectra with segmenting continuous process cohgramc Multi taper time frequency coherence cross spectrum and individual spectra continuous processes SOURCE CODE 0001 function C phi S12 S1 S2 f confC phistd Cerr coherencyc data1 data2 params 0002 Multi taper coherency cross spectrum and individual spectra continuous process 0003 0004 Usage 0005 C phi S12 S1 S2 f confC phistd Cerr coherencyc data1 data2 params 0006 Input 0007 Note units have to be consistent See chronux m for more information 0008 data1 in form samples x trials required 0009 data2 in form samples x trials required 0010 params structure with fields tapers pad Fs fpass err trialave 0011 optional 0012 tapers precalculated tapers from dpss or in the one of the following 0013 forms 0014 1 A numeric vector TW K where TW is the 0015 time bandwidth product and K is the number of 0016 tapers to be used less than or equal to 0017 2TW 1 0018 2 A numeric vector W T p where W is the 0019 bandwidth T is the duration of the data and p 0020 is an integer such that 2TW p tapers are used In 0021 this form there is no default i e to specify 0022 the bandwidth you have to specify T and p as 0023 well Note that the units of W and T have to be 0024 consistent if W is in Hz T must be in seconds 0025 and vice versa Note that these units must also 0026 be consistent with the units of params Fs W can 0027 be in Hz if and only if params Fs is in Hz 0028 The default is to use form 1 with TW 3 and K 5 0029 0030 pad padding factor for the FFT optional can take values 1 0 1 2 0031 1 corresponds to no padding 0 corresponds to padding 0032 to the next highest power of 2 etc 0033 e g For N 500 if PAD 1 we do not pad if PAD 0 we pad the FFT 0034 to 512 points if pad 1 we pad to 1024 points etc 0035 Defaults to 0 0036 Fs sampling frequency optional Default 1 0037 fpass frequency band to be used in the calculation in the form 0038 fmin fmax optional 0039 Default all frequencies between

    Original URL path: http://www.chronux.org/Documentation/chronux/spectral_analysis/continuous/coherencyc.html (2015-03-27)
    Open archived version from archive

  • Description of fig6_6
    This function calls This function is called by runbook SOURCE CODE 0001 Local Regression and Likelihood Figure 6 6 0002 Author Catherine Loader 0003 0004 Penny data estimating jump size using left and 0005 right smooths 0006 0007 0008 load penny 0009 midp 1945 1988 0 5 0010 fitl locfit year thickness style l alpha 0 10 ev midp deg 1 0011 fitr locfit year thickness style r alpha 0

    Original URL path: http://www.chronux.org/Documentation/chronux/locfit/Book/fig6_6.html (2015-03-27)
    Open archived version from archive

  • Description of mtspecgramc
    bars 2 p Jackknife error bars 0 p or 0 no error bars optional Default 0 trialave average over trials channels when 1 don t average when 0 optional Default 0 Output S spectrum in form time x frequency x channels trials if trialave 0 in the form time x frequency if trialave 1 t times f frequencies Serr error bars only for err 1 1 CROSS REFERENCE INFORMATION This function calls mtspectrumc Multi taper spectrum continuous process This function is called by mtspecgramtrigc Multi taper event triggered time frequency spectrum continuous process SOURCE CODE 0001 function S t f Serr mtspecgramc data movingwin params 0002 Multi taper time frequency spectrum continuous process 0003 0004 Usage 0005 S t f Serr mtspecgramc data movingwin params 0006 Input 0007 Note units have to be consistent Thus if movingwin is in seconds Fs 0008 has to be in Hz see chronux m for more information 0009 data in form samples x channels trials required 0010 movingwin in the form window winstep i e length of moving 0011 window and step size 0012 Note that units here have 0013 to be consistent with 0014 units of Fs required 0015 params structure with fields tapers pad Fs fpass err trialave 0016 optional 0017 tapers precalculated tapers from dpss or in the one of the following 0018 forms 0019 1 A numeric vector TW K where TW is the 0020 time bandwidth product and K is the number of 0021 tapers to be used less than or equal to 0022 2TW 1 0023 2 A numeric vector W T p where W is the 0024 bandwidth T is the duration of the data and p 0025 is an integer such that 2TW p tapers are used In 0026 this form there is no default i e to specify 0027 the bandwidth you have to specify T and p as 0028 well Note that the units of W and T have to be 0029 consistent if W is in Hz T must be in seconds 0030 and vice versa Note that these units must also 0031 be consistent with the units of params Fs W can 0032 be in Hz if and only if params Fs is in Hz 0033 The default is to use form 1 with TW 3 and K 5 0034 Note that T has to be equal to movingwin 1 0035 0036 pad padding factor for the FFT optional can take values 1 0 1 2 0037 1 corresponds to no padding 0 corresponds to padding 0038 to the next highest power of 2 etc 0039 e g For N 500 if PAD 1 we do not pad if PAD 0 we pad the FFT 0040 to 512 points if pad 1 we pad to 1024 points etc 0041 Defaults to 0 0042 Fs sampling frequency optional Default 1 0043 fpass frequency band to be used in the calculation in the form 0044 fmin fmax optional 0045 Default all frequencies between 0

    Original URL path: http://www.chronux.org/Documentation/chronux/spectral_analysis/continuous/mtspecgramc.html (2015-03-27)
    Open archived version from archive

  • Description of spence15
    which isn t the shortest computer program 0005 0006 osev ones 7 1 0007 n length y 0008 y osev y 1 y osev y n 0009 0010 n length y 0011 k 3 n 2 0012 a3 y k 1 y k y k 1 0013 a2 y k 2 y k 2 0014 y1 y k 3 a3 a2 0015 0016 n length y1 0017 k 1 n

    Original URL path: http://www.chronux.org/Documentation/chronux/locfit/m/spence15.html (2015-03-27)
    Open archived version from archive

  • Description of coherencyc_unequal_length_trials
    only for those segments whose length NW 2 For that reason the routine returns the 0046 indices for segments for which the spectra is computed This check is 0047 done here since pSpecgramAvg calls it 0048 0049 iwAvg 1 0 no weighted average 1 weighted average 0050 debug 1 will display intermediate calcs 0051 0052 if nargin 2 error avgCoherence Need data and window parameters end 0053 if nargin 3 params end 0054 tapers pad Fs fpass err trialave params getparams params 0055 if isempty sMarkers error avgCoherence Need Markers end 0056 Not designed for trialave so set to 0 0057 params trialave 0 0058 tapers pad Fs fpass err trialave params getparams params 0059 if nargout 7 err 1 2 0060 error avgCoherence Cerr computed only for Jackknife Correct inputs and run again 0061 end 0062 if nargout 5 err 1 0 0063 Errors computed only if err 1 is nonzero Need to change params and run again 0064 error avgCoherence When errors are desired err 1 has to be non zero 0065 end 0066 if size data 2 1 error avgCoherence Need more than 1 channel to compute coherence end 0067 0068 Set moving window parameters to no overlapping 0069 if abs movingwin 2 movingwin 1 1e 6 disp avgCoherence Warming Window parameters for averaging should be non overlapping Set movingwin 2 movingwin 1 end 0070 0071 wLength round Fs movingwin 1 number of samples in window 0072 wStep round movingwin 2 Fs number of samples to step through 0073 0074 Check whether window lengths satify segment length NW 2 0075 if wLength 2 tapers 1 error avgCoherence movingwin 1 2 tapers 1 end 0076 0077 Left align segment markers for easier coding 0078 sM ones size sMarkers 1 2 0079 sM 2 sMarkers 2 sMarkers 1 1 0080 0081 min max segments 0082 Nmax max sM 2 Nmin min sM 2 0083 if Nmin 2 tapers 1 error avgCoherence Smallest segment length 2 tapers 1 Change taper settings end 0084 0085 max time sample length will be the window length 0086 nfft 2 nextpow2 wLength pad 0087 f findx getfgrid Fs nfft fpass 0088 0089 Precompute all the tapers 0090 sTapers tapers 0091 sTapers dpsschk sTapers wLength Fs compute tapers for window length 0092 0093 nChannels size data 2 0094 nSegments size sMarkers 1 0095 iChPairs ceil nChannels nChannels 1 2 0096 0097 if debug 0098 disp Window Length num2str wLength 0099 disp Window Step num2str wStep 0100 disp 0101 end 0102 0103 0104 coherr outputs such that 0105 confc is has dimensions 1 size cmn 2 confc 1 x iChPairs 0106 phistd has dimensions f size cmn 2 phistd frequencies x iChPairs size cmn 0107 cerr has dimensions 2 size cmn cerr 2 x frequencies x iChPairs 0108 0109 cerr zeros 2 length f iChPairs confc zeros 1 iChPairs phistd zeros length f iChPairs 0110 Cerr zeros 2 length f iChPairs ConfC zeros 1 iChPairs PhiStd zeros length f iChPairs 0111 0112 serr zeros 2 length

    Original URL path: http://www.chronux.org/Documentation/chronux/spectral_analysis/continuous/coherencyc_unequal_length_trials.html (2015-03-27)
    Open archived version from archive

  • Description of fig6_7
    called by runbook SOURCE CODE 0001 Local Regression and Likelihood Figure 6 6 0002 Author Catherine Loader 0003 0004 Penny data piecewise smoothing 0005 0006 0007 load penny 0008 u find year 1958 0009 fit1 locfit year u thickness u alpha 0 10 deg 1 0010 u find year 1958 year 1974 0011 fit2 locfit year u thickness u alpha 0 10 deg 1 0012 u find year 1974 0013

    Original URL path: http://www.chronux.org/Documentation/chronux/locfit/Book/fig6_7.html (2015-03-27)
    Open archived version from archive



  •