def loopalt_gtd(time: datetime,<EOL>glat: Union[float, np.ndarray], glon: Union[float, np.ndarray],<EOL>altkm: Union[float, List[float], np.ndarray], *,<EOL>f107a: float = None, f107: float = None, Ap: int = None) -> xarray.Dataset:
glat = np.atleast_2d(glat)<EOL>glon = np.atleast_2d(glon)<EOL>assert glat.ndim == glon.ndim == <NUM_LIT:2><EOL>times = np.atleast_1d(time)<EOL>assert times.ndim == <NUM_LIT:1><EOL>atmos = xarray.Dataset()<EOL>for k, t in enumerate(times):<EOL><INDENT>print('<STR_LIT>', t)<EOL>for i in range(glat.shape[<NUM_LIT:0>]):<EOL><INDENT>for j in range(glat.shape[<NUM_LIT:1>]):<EOL><INDENT>atm = rungtd1d(t, altkm, glat[i, j], glon[i, j],<EOL>f107a=f107a, f107=f107, Ap=Ap)<EOL>atmos = xarray.merge((atmos, atm))<EOL><DEDENT><DEDENT><DEDENT>atmos.attrs = atm.attrs<EOL>return atmos<EOL>
loop over location and time

time: datetime or numpy.datetime64 or list of datetime or np.ndarray of datetime
glat: float or 2-D np.ndarray
glon: float or 2-D np.ndarray
altkm: float or list or 1-D np.ndarray