diff options
author | Weitian LI <liweitianux@gmail.com> | 2014-06-24 15:30:24 +0800 |
---|---|---|
committer | Weitian LI <liweitianux@gmail.com> | 2014-06-24 15:30:24 +0800 |
commit | f65dcae0b995c26fceba31a5ca30a988a4eb02b1 (patch) | |
tree | 89fc2e722b91d66c0a25612db914ddd480446587 /scripts/ciao_calc_ct.sh | |
parent | e3923265d0d6949407a83726e9a9bd5d97079221 (diff) | |
download | chandra-acis-analysis-f65dcae0b995c26fceba31a5ca30a988a4eb02b1.tar.bz2 |
Updated scripts and added some files
* Updated 'ciao_calc_csb.sh', 'ciao_calc_ct.sh'
* Added 'make_infojson.sh' for wjy's data
* Added some files:
- fitting_mass.conf
- fitting_sbp.conf
- wang2012_param.txt
Diffstat (limited to 'scripts/ciao_calc_ct.sh')
-rwxr-xr-x | scripts/ciao_calc_ct.sh | 27 |
1 files changed, 14 insertions, 13 deletions
diff --git a/scripts/ciao_calc_ct.sh b/scripts/ciao_calc_ct.sh index 6fb1d79..926c785 100755 --- a/scripts/ciao_calc_ct.sh +++ b/scripts/ciao_calc_ct.sh @@ -19,18 +19,6 @@ export LC_COLLATE=C ## 2014/06/18: 'cooling_time2.sh' -> 'ciao_calc_ct.sh' ########################################################### -## comology calculator {{{ -## XXX: MODIFY THIS TO YOUR OWN CASE -## and make sure this `calc' is executable -## NOTES: use `$HOME' instead of `~' in path -BASE_PATH=`dirname $0` -COSCALC="`which cosmo_calc calc_distance | head -n 1`" -if [ -z "${COSCALC}" ] || [ ! -x ${COSCALC} ]; then - printf "ERROR: \`COSCALC: ${COSCALC}' neither specified nor executable\n" - exit 255 -fi -## }}} - ## about, used in `usage' {{{ VERSION="v1.1" UPDATE="2012-08-26" @@ -57,7 +45,7 @@ ERR_UNI=61 case "$1" in -[hH]*|--[hH]*) printf "usage:\n" - printf " `basename $0` evt=<evt2_clean> r500=<r500_kpc> regin=<input_reg> regout=<output_reg> bkgd=<blank_evt | lbkg_reg | bkg_spec> nh=<nH> z=<redshift> arf=<warf_file> rmf=<wrmf_file> [ grpcmd=<grppha_cmd> log=<log_file> ]\n" + printf " `basename $0` basedir=<repro_dir> evt=<evt2_clean> r500=<r500_kpc> regin=<input_reg> regout=<output_reg> bkgd=<blank_evt | lbkg_reg | bkg_spec> nh=<nH> z=<redshift> arf=<warf_file> rmf=<wrmf_file> [ grpcmd=<grppha_cmd> log=<log_file> ]\n" printf "\nversion:\n" printf "${VERSION}, ${UPDATE}\n" exit ${ERR_USG} @@ -65,6 +53,18 @@ case "$1" in esac ## usage, help }}} +## comology calculator {{{ +## XXX: MODIFY THIS TO YOUR OWN CASE +## and make sure this `calc' is executable +## NOTES: use `$HOME' instead of `~' in path +BASE_PATH=`dirname $0` +COSCALC="`which cosmo_calc calc_distance 2>/dev/null | head -n 1`" +if [ -z "${COSCALC}" ] || [ ! -x ${COSCALC} ]; then + printf "ERROR: \`COSCALC: ${COSCALC}' neither specified nor executable\n" + exit 255 +fi +## }}} + ## default parameters {{{ # default `event file' which used to match `blanksky' files #DFT_EVT="_NOT_EXIST_" @@ -208,6 +208,7 @@ if [ -d "${basedir}" ]; then else BASEDIR=${DFT_BASEDIR} fi +# json file if [ ! -z "${json}" ] && [ -r "${BASEDIR}/${json}" ]; then JSON_FILE="${BASEDIR}/${json}" elif [ `ls ${BASEDIR}/${DFT_JSON_PAT} 2> /dev/null | wc -l` -eq 1 ]; then |