13 using Upvd_t = std::unique_ptr<TVectorD>;
23 TString dir = gROOT->GetTutorialDir();
26 TFITSHDU hdu(dir +
"/fitsio/sample4.fits[1]");
29 std::array<Upvd_t, 2> vs{Upvd_t(hdu.GetTabRealVectorCell(0,
"mag")), Upvd_t(hdu.GetTabRealVectorCell(1,
"mag"))};
31 for(
auto i : ROOT::TSeqI(v->GetNoElements())) {
34 printf(
"%lg", (*v)[i]);
40 std::unique_ptr<TObjArray> vectorCollection(hdu.GetTabRealVectorCells(
"mag"));
41 for (
auto vObj : *vectorCollection) {
42 auto &v = *
static_cast<TVectorD*
>(vObj);
43 for (
auto i : ROOT::TSeqI(v.GetNoElements())) {
44 if (i > 0) printf(
", ");
45 printf(
"%lg", (v[i]));