From 0c9714a8e41567ac15cc9f79d67d9c7e24fa55b5 Mon Sep 17 00:00:00 2001 From: Jeremy Faden Date: Tue, 30 Apr 2024 07:19:01 -0500 Subject: [PATCH] https://github.com/das-developers/das2java/issues/107: second demo of bundle --- bugs/2024/20240429/demoBundleBMagBug.jy | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 bugs/2024/20240429/demoBundleBMagBug.jy diff --git a/bugs/2024/20240429/demoBundleBMagBug.jy b/bugs/2024/20240429/demoBundleBMagBug.jy new file mode 100644 index 00000000..a341e128 --- /dev/null +++ b/bugs/2024/20240429/demoBundleBMagBug.jy @@ -0,0 +1,25 @@ +setScriptDescription('''Autoplot never exposes bundled data +xtags, so you need to explicitly add them in. I believe +it's because if I automatically look for DEPEND_0 on any of +the bundled datasets, then sometimes a variable intended for +the X values is ignored. There really needs to be something +that disambiguates this.''') + +# here is where it is not intended to assert a depenency. +BXYZ= getDataSet('vap+hapi:https://cdaweb.gsfc.nasa.gov/hapi?id=AC_K0_MFI&timerange=2024-04-20¶meters=Time,BGSEc') +BX= unbundle(BXYZ,0) +BY= unbundle(BXYZ,1) +BZ= unbundle(BXYZ,2) + +ds= bundle( BX, BY, BZ ) + +print ds +print xtags(ds) +print xtags(unbundle(ds,0)) + +plot( 0, ds ) + +ds= bundle( BX, BY, BZ ) +ds= dataset( xtags(BX),ds ) + +plot( 1, ds )