Commit 145f603f authored by CD's avatar CD
Browse files

small changes to physiological variable output helper functions

parent f7dd10c3
......@@ -248,9 +248,9 @@
;When physiology is enabled
(when (and (get-module physio) (phys-module-enabled phys))
(if test
(if (probe-file (concatenate 'string "CEC-Arous" *START-TIME* ".txt"))
(if (probe-file (concatenate 'string "Phys-data/CEC-Arous" (phys-module-pipeID phys) ".txt"))
(with-open-file
(msgStream (concatenate 'string "CEC-Arous" *START-TIME* ".txt")
(msgStream (concatenate 'string "Phys-data/CEC-Arous" (phys-module-pipeID phys) ".txt")
:direction :output :if-exists :append :if-does-not-exist :create)
(format msgStream "~5$,~5$,~5$,~5$~&"
(compute-cort test) (compute-epi-arousal test) (compute-crh-arousal test)
......@@ -260,7 +260,7 @@
(compute-epi-arousal))
(* (AA-crh-arous-ratio aa) (compute-crh-arousal))))))
(with-open-file
(msgStream (concatenate 'string "CEC-Arous" *START-TIME* ".txt")
(msgStream (concatenate 'string "Phys-data/CEC-Arous" (phys-module-pipeID phys) ".txt")
:direction :output :if-exists :supersede :if-does-not-exist :create)
(format msgStream "f(Cortisol),g(Epinephrine),h(CRH),Arousal~&"))))
(* (compute-homeostatic-arousal-factor) (compute-cort)
......@@ -300,7 +300,7 @@
(setf ret-arousal 1))
(if test
(with-open-file
(msgStream (concatenate 'string "Homeostatic-Arousal" *START-TIME* ".txt")
(msgStream (concatenate 'string "Phys-data/Homeostatic-Arousal" (phys-module-pipeID phys) ".txt")
:direction :output :if-exists :append :if-does-not-exist :create)
(format msgStream "~5$~&" ret-arousal)))
ret-arousal))
......
......@@ -971,7 +971,7 @@ t)
;Write to output file if we are testing things
(if test
(with-open-file
(msgStream (concatenate 'string "CRH-Raw" *START-TIME* ".txt")
(msgStream (concatenate 'string "Phys-data/CRH-Raw" (phys-module-pipeID phys) ".txt")
:direction :output :if-exists :append :if-does-not-exist :create)
(format msgStream "~S~T~10$~T~10$~&" crh-stress crh crh-base)))
;Return the CRH factor or 0 if less than 0
......@@ -990,7 +990,7 @@ t)
;Write to output file if we are testing things
(if test
(with-open-file
(msgStream (concatenate 'string "EPI-RAW" *START-TIME* ".txt")
(msgStream (concatenate 'string "Phys-data/EPI-RAW" (phys-module-pipeID phys) ".txt")
:direction :output :if-exists :append :if-does-not-exist :create)
(format msgStream "~10$~T~10$~&" epi epi-base)))
;Return the epi factor or 0 if less than 0
......@@ -1057,7 +1057,7 @@ t)
;Write to output file if we are testing things
(if test
(with-open-file
(msgStream (concatenate 'string "CORT-RAW" *START-TIME* ".txt")
(msgStream (concatenate 'string "Phys-data/CORT-RAW" (phys-module-pipeID phys) ".txt")
:direction :output :if-exists :append :if-does-not-exist :create)
(format msgStream "~5$~T~5$~T~5$~T~5$~&" cort cort-base cort-ratio cort-ratio-base)))
;Return the cort factor or 0 if less than 0
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment