making calc specific to data frames