I have seen discussions of unwanted nulls in the output in the context of building lists with conditions on the elements, but that is not involved here. I would like to know where the nulls come from and how to avoid generating them.
Clear["Global`*"]
localGroup =
AstronomicalData["LocalGroup"];
properties = {
"AlphanumericName",
"StandardName",
"AlternateStandardNames",
"NGCNumber",
"ApparentMagnitude",
"Constellation",
"Declination",
"RightAscension",
"DistanceLightYears",
"GalaxyType",
"HubbleType",
"RadialVelocity",
"Redshift"
};
lgTable = {#, Table[
{
properties[[n]],
AstronomicalData[#, properties[[n]]]
},
{n, 1, Length[properties]}
]
} & /@ localGroup;
displayTable[record_] := Module[{},
Print[
#[[1]] <> ": ", #[[2]]
] & /@ record[[2]];
Print["\n"]
]
(* display two records for illustration *)
displayTable[#] & /@ lgTable[[1 ;; 2]]
