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 jackknife
    jackknife estimates of the mean and standard deviation of input data x 0003 Usage m jsd jackknife x 0004 0005 Inputs 0006 x data in the form samples x trials 0007 0008 Outputs 0009 m estimate of the mean across trials 0010 jsd jackknife estimate of the standard deviation across trials 0011 0012 N C size x 0013 if C 1 error Need multiple trials end 0014 m mean x

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


  • Description of plx_ad
    in this fragment 0013 All the data values stored in the vector ad 0014 OUTPUT 0015 n total number of data points 0016 ts array of fragment timestamps one timestamp for fragment in seconds 0017 fn number of data points in each fragment 0018 ad array of raw a d values 0019 0020 if nargin 2 0021 disp 2 input arguments are required 0022 return 0023 end 0024 0025 i 0 0026 n 0 0027 ts 0 0028 fn 0 0029 ad 0 0030 0031 if isempty filename 0032 fname pathname uigetfile plx Select a plx file 0033 filename strcat pathname fname 0034 end 0035 0036 fid fopen filename r 0037 if fid 1 0038 disp cannot open file 0039 return 0040 end 0041 0042 calculate file size 0043 fseek fid 0 eof 0044 fsize ftell fid 0045 fseek fid 0 bof 0046 0047 0048 disp strcat file filename 0049 0050 read file header 0051 header fread fid 64 int32 0052 freq header 35 frequency 0053 ndsp header 36 number of dsp channels 0054 nevents header 37 number of external events 0055 nslow header 38 number of slow channels 0056 npw header 39 number of points in wave 0057 npr header 40 number of points before threshold 0058 tscounts fread fid 5 130 int32 0059 wfcounts fread fid 5 130 int32 0060 evcounts fread fid 1 512 int32 0061 0062 A D counts are stored in evcounts 301 302 etc 0063 count 0 0064 if evcounts 301 ch 0 0065 count evcounts 301 ch 0066 ad 1 count 0067 end 0068 0069 skip DSP and Event headers 0070 fseek fid 1020 ndsp 296 nevents cof 0071 0072 read one A D header and get the frequency 0073 adheader fread fid 74 int32 0074 adfreq adheader 10 0075 0076 skip all

    Original URL path: http://www.chronux.org/Documentation/chronux/dataio/ReadingPLXandDDTfilesinMatlab/plx_ad.html (2015-03-27)
    Open archived version from archive

  • Description of FAnalyze
    0281 v handles zone i v 1 data 0282 vtheta handles zone i vtheta 1 data 0283 0284 0285 stops indx find v speed thresh 1 0286 moves indx find v speed thresh 1 0287 0288 v stops indx 0 vx stops indx 0 vy stops indx 0 vtheta atan2 vy vx 0289 0290 0291 handles zone i seg label seg names 0292 handles zone i t 2 data t stops indx 0293 handles zone i x 2 data x stops indx 0294 handles zone i y 2 data y stops indx 0295 handles zone i r 2 data r stops indx 0296 handles zone i theta 2 data theta stops indx 0297 handles zone i vx 2 data vx stops indx 0298 handles zone i vy 2 data vy stops indx 0299 handles zone i v 2 data v stops indx 0300 handles zone i vtheta 2 data vtheta stops indx 0301 handles zone i tau 2 data FindDuration stops indx 0302 handles zone i kappa 2 data N A 0303 0304 0305 for j 2 length speed thresh 0306 0307 indxA find v speed thresh j 1 v speed thresh j 0308 indxB find v speed thresh j 0309 0310 handles zone i t j 1 data t indxA 0311 handles zone i x j 1 data x indxA 0312 handles zone i y j 1 data y indxA 0313 handles zone i r j 1 data r indxA 0314 handles zone i theta j 1 data theta indxA 0315 handles zone i vx j 1 data vx indxA 0316 handles zone i vy j 1 data vy indxA 0317 handles zone i v j 1 data v indxA 0318 handles zone i vtheta j 1 data vtheta indxA 0319 handles zone i tau j 1 data FindDuration indxA 0320 handles zone i kappa j 1 data CalcCurvature v vtheta indxA 1 fps 0321 0322 handles zone i t j 2 data t indxB 0323 handles zone i x j 2 data x indxB 0324 handles zone i y j 2 data y indxB 0325 handles zone i r j 2 data r indxB 0326 handles zone i theta j 2 data theta indxB 0327 handles zone i vx j 2 data vx indxB 0328 handles zone i vy j 2 data vy indxB 0329 handles zone i v j 2 data v indxB 0330 handles zone i vtheta j 2 data vtheta indxB 0331 handles zone i tau j 2 data FindDuration indxB 0332 handles zone i kappa j 2 data CalcCurvature v vtheta indxB 1 fps 0333 0334 end 0335 handles zone i beta 1 data CalcReorientAngle vtheta moves indx 0336 n n 1 0337 end 0338 0339 0340 temp3 0341 sz size temp list 0342 for q 1 sz 2 0343 temp3 temp3 temp list q 0344 end 0345 0346 disp Speed has been segmented 0347 update listbox handles temp3 0348 guidata gcbo handles 0349 0350 Executes on button press in load traj 0351 function load traj Callback hObject eventdata handles 0352 hObject handle to load traj see GCBO 0353 eventdata reserved to be defined in a future version of MATLAB 0354 handles structure with handles and user data see GUIDATA 0355 0356 filename pathname uigetfile mat Select the mat file containing the trajectory MultiSelect off 0357 0358 if isequal filename 0 isequal pathname 0 0359 disp File select canceled 0360 return 0361 else 0362 disp File selected fullfile pathname filename 0363 load fullfile pathname filename 0364 handles filename fullfile pathname filename 0365 0366 end 0367 0368 0369 handles zone 1 t 1 data t 0370 handles fps 1 t 2 t 1 0371 handles zone 1 x 1 data x 0372 handles zone 1 y 1 data y 0373 0374 guidata gcbo handles 0375 0376 Executes on button press in smooth 0377 function smooth Callback hObject eventdata handles 0378 hObject handle to smooth see GCBO 0379 eventdata reserved to be defined in a future version of MATLAB 0380 handles structure with handles and user data see GUIDATA 0381 0382 grab data 0383 t handles zone 1 t 1 data 0384 fps handles fps 0385 x handles zone 1 x 1 data 0386 y handles zone 1 y 1 data 0387 handles P 0388 0389 grab smoothing parameters as input by the user 0390 n str2double get handles n String 0391 dn str2double get handles dn String 0392 0393 disp Smoothing data Please wait 0394 smooth using runline 0395 x runline x n dn 0396 y runline y n dn 0397 0398 Calculate polar coords and velocity 0399 r sqrt x 2 y 2 0400 theta atan2 y x 0401 0402 vx fps gradient x 0403 vy fps gradient y 0404 v sqrt vx 2 vy 2 0405 vtheta atan2 vy vx 0406 0407 clear handles x 0408 clear handles y 0409 save smooth data to handles to be used by other GUI functions 0410 handles zone names 1 Full Arena 0411 handles zone 1 zone label Full Arena 0412 handles zone 1 seg label all 0413 handles zone 1 t 1 data t 0414 handles zone 1 x 1 data x 0415 handles zone 1 y 1 data y 0416 0417 handles zone 1 r 1 data r 0418 handles zone 1 theta 1 data theta 0419 handles zone 1 vx 1 data vx 0420 handles zone 1 vy 1 data vy 0421 handles zone 1 v 1 data v 0422 handles zone 1 vtheta 1 data vtheta 0423 handles zone 1 tau 1 data N A 0424 handles zone 1 kappa 1 data N A 0425 0426 0427 0428 disp Trajectory has been smoothed 0429 0430 update listbox handles x Full Arena all y Full Arena all r Full Arena all theta Full Arena all 0431 vx Full Arena all vy Full Arena all v Full Arena all vtheta Full Arena all 0432 guidata gcbo handles 0433 0434 function n Callback hObject eventdata handles 0435 hObject handle to n see GCBO 0436 eventdata

    Original URL path: http://www.chronux.org/Documentation/chronux/fly_track/FAnalyze/functions/FAnalyze.html (2015-03-27)
    Open archived version from archive

  • Description of fig11_1
    CROSS REFERENCE INFORMATION This function calls This function is called by runbook SOURCE CODE 0001 Local Regression and Likelihood Figure 11 1 0002 0003 Variable degree fit uses module vord Note there is 0004 no lower degree here it defaults to 0 0005 0006 Author Catherine Loader 0007 0008 load ethanol 0009 0010 figure Name fig11 1a Variable degree fit 0011 fit locfit E NOx deg 3 nn 0 3

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

  • Description of kappa0
    kappa0 function as the kappa argument to a predict or lfband call Example load ethanol fit locfit E NOx alpha 0 5 kap kappa0 E NOx alpha 0 5 give same arguments lfplot fit lfband fit kappa kap plot the simultaneous bands z predict fit 0 6 0 7 0 8 kappa kap band g z 3 evaluate the bands CROSS REFERENCE INFORMATION This function calls locfit Smoothing noisy data using Local Regression and Likelihood This function is called by scb Simultaneous Confidence Bands SOURCE CODE 0001 function kap kappa0 x y varargin 0002 0003 Compute the constants for tube formula based simultaneous 0004 confidence bands 0005 0006 Works for regression models only Density estimation problems 0007 should be converted to counts and use poisson regression 0008 family poisson 0009 0010 Essentially this is a front end to locfit and so all optional 0011 arguments to locfit eg smoothing parameters can be provided 0012 0013 To compute or plot the confidence bands provide the output 0014 of the kappa0 function as the kappa argument to a 0015 predict or lfband call 0016 0017 0018 Example 0019 0020 load ethanol 0021 fit locfit E NOx alpha 0 5 0022 kap kappa0

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

  • Description of plx_event_ts
    filename if empty string will use File Open dialog 0008 channel 1 based external channel number 0009 strobed channel has channel number 257 0010 OUTPUT 0011 n number of timestamps 0012 ts array of timestamps 0013 sv array of strobed event values filled only if channel is 257 0014 0015 if nargin 2 0016 disp 2 input arguments are required 0017 return 0018 end 0019 0020 n 0 0021 ts 0 0022 sv 0 0023 0024 if isempty filename 0025 fname pathname uigetfile plx Select a plx file 0026 filename strcat pathname fname 0027 end 0028 0029 fid fopen filename r 0030 if fid 1 0031 disp cannot open file 0032 return 0033 end 0034 0035 disp strcat file filename 0036 0037 read file header 0038 header fread fid 64 int32 0039 freq header 35 frequency 0040 ndsp header 36 number of dsp channels 0041 nevents header 37 number of external events 0042 nslow header 38 number of slow channels 0043 npw header 39 number of points in wave 0044 npr header 40 number of points before threshold 0045 tscounts fread fid 5 130 int32 0046 wfcounts fread fid 5 130 int32 0047 evcounts fread fid 1 512 int32 0048

    Original URL path: http://www.chronux.org/Documentation/chronux/dataio/ReadingPLXandDDTfilesinMatlab/plx_event_ts.html (2015-03-27)
    Open archived version from archive

  • Description of FTrack
    to be defined in a future version of MATLAB 0213 handles structure with handles and user data see GUIDATA 0214 0215 0216 Opens up a dialog box so that the user can input relevant parameters for 0217 each video that is being tracked A separate box will open for each 0218 video 0219 0220 filename handles filename 0221 if iscell filename 0222 NFiles length filename 0223 else 0224 Nfiles 1 0225 filename filename 0226 end 0227 UserIn 0228 0229 for i 1 NFiles 0230 first strvcat filename i Output directory 0231 prompt first Start Frame Remember that first frame is indexed 0 End Frame Initial background size Arena radius cm Bounding box half size in pixels Background weight 0 9 a 1 0232 dlg title Input Paramters 0233 num lines 1 0234 defaults C Documents and Settings liam My Documents LabVIEW Data FTrack output 0 999 100 7 5 10 0 9 0235 options Resize on 0236 options WindowStyle normal 0237 answer inputdlg prompt dlg title num lines defaults options 0238 UserIn UserIn answer 0239 disp Input parameters have been entered for filename i 0240 0241 InputData i OutputPath UserIn 1 i 0242 InputData i StartFrame str2double UserIn 2 i 0243 InputData i EndFrame str2double UserIn 3 i 0244 InputData i NBackFrames str2double UserIn 4 i 0245 InputData i ArenaRadius str2double UserIn 5 i 0246 InputData i sqrsize str2double UserIn 6 i 0247 InputData i alpha str2double UserIn 7 i 0248 0249 end 0250 0251 handles InputData InputData 0252 0253 guidata gcbo handles 0254 0255 0256 Radio Buttons to select fly finding option 0257 0258 Executes during object creation after setting all properties 0259 function find opt CreateFcn hObject eventdata handles 0260 hObject handle to find opt see GCBO 0261 eventdata reserved to be defined in a future version of MATLAB 0262 handles empty handles not created until after all CreateFcns called 0263 0264 0265 0266 function find opt SelectionChangeFcn hObject eventdata handles 0267 hObject handle to find opt see GCBO 0268 eventdata reserved to be defined in a future version of MATLAB 0269 handles structure with handles and user data see GUIDATA 0270 0271 0272 Radio buttons to select whether fly is white on black or black on white 0273 0274 Executes during object creation after setting all properties 0275 function neg opt CreateFcn hObject eventdata handles 0276 hObject handle to neg opt see GCBO 0277 eventdata reserved to be defined in a future version of MATLAB 0278 handles empty handles not created until after all CreateFcns called 0279 0280 0281 function neg opt SelectionChangeFcn hObject eventdata handles 0282 hObject handle to neg opt see GCBO 0283 eventdata reserved to be defined in a future version of MATLAB 0284 handles structure with handles and user data see GUIDATA 0285 0286 0287 0288 Executes on button press in TrackStart 0289 function TrackStart Callback hObject eventdata handles 0290 hObject handle to TrackStart see GCBO 0291 eventdata reserved to be defined in a future version of MATLAB 0292 handles structure with handles and user data see GUIDATA 0293 0294 This part of the calls FlyTracker to do the actual tracking 0295 0296 grab the filename and user input parameters 0297 filename handles filename 0298 InputData handles InputData 0299 0300 if iscell filename 0301 NVideos length filename 0302 else 0303 NVideos 1 0304 filename filename 0305 end 0306 0307 neg opt get get handles neg opt SelectedObject Tag 0308 0309 Call FlyTracker 0310 for i 1 NVideos 0311 0312 video parameters just because 0313 info handles VideoInfo i 0314 FrameRate info fps 0315 FrameRange InputData i StartFrame InputData i EndFrame 0316 0317 Track the fly 0318 x y orientation FlyTracker filename i FrameRange 0319 InputData i NBackFrames neg opt InputData i sqrsize 0320 InputData i alpha handles arena i 0321 0322 Time vector 0323 if info numFrames InputData i EndFrame 0324 InputData i EndFrame InputData i EndFrame 1 0325 elseif info numFrames InputData i EndFrame 0326 InputData i EndFrame info numFrames 1 0327 end 0328 0329 t InputData i StartFrame InputData EndFrame i FrameRate 0330 0331 Save data to handles so the rest of the GUI can access it 0332 handles x x 0333 handles y y 0334 handles orientation orientation 0335 handles t t 0336 0337 guidata gcbo handles 0338 Also save variables as a mat file so that the user will be able to 0339 load in the tracked data later on 0340 0341 out SaveFiles i handles 0342 0343 end 0344 disp Tracking Complete 0345 0346 0347 0348 0349 Executes on button press in view traj 0350 function view traj Callback hObject eventdata handles 0351 hObject handle to view traj see GCBO 0352 eventdata reserved to be defined in a future version of MATLAB 0353 handles structure with handles and user data see GUIDATA 0354 0355 filename pathname 0356 uigetfile mat Select Raw Trajectory Data 0357 0358 if isequal filename 0 isequal pathname 0 0359 disp File select canceled 0360 return 0361 else 0362 fullname fullfile pathname filename 0363 end 0364 0365 0366 load fullname 0367 figure 0368 set gcf Name fullname 0369 subplot 2 2 1 0370 plot t x 0371 xlim 0 t end 0372 xlabel Time s 0373 ylabel cm 0374 title Raw x data 0375 subplot 2 2 3 0376 plot t y 0377 xlim 0 t end 0378 xlabel Time s 0379 ylabel cm 0380 title Raw y data 0381 subplot 2 2 2 4 0382 plot x y 0383 xlabel x position cm 0384 ylabel y position cm 0385 title Raw Trajectory 0386 axis equal 0387 0388 handles filename filename 0389 handles x x 0390 handles y y 0391 handles orientation orientation 0392 handles t t 0393 handles VideoInfo VideoInfo 0394 handles InputData InputData 0395 handles arena 1 arena 0396 0397 guidata gcbo handles 0398 0399 0400 0401 0402 Executes on button press in clean x 0403 function clean x Callback hObject eventdata handles 0404 hObject handle to clean x see GCBO 0405 eventdata reserved to be defined in a future version of MATLAB

    Original URL path: http://www.chronux.org/Documentation/chronux/fly_track/FTrack/functions/FTrack.html (2015-03-27)
    Open archived version from archive

  • Description of fig11_4
    is hard to see CROSS REFERENCE INFORMATION This function calls This function is called by runbook SOURCE CODE 0001 Local Regression and Likelihood Figure 11 4 0002 Author Catherine Loader 0003 0004 Local Adaptive Smooth Dopler example 0005 0006 NEED Improve plot curve is hard to see 0007 0008 x 0 2047 2047 0009 m 20 sqrt x 1 x sin 2 pi 1 05 x 0 05 0010 y

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



  •