[R] FW: How to create a new data.frame based on calculation of subsets of an existing data.frame

2019-12-17 Thread ioanna ioannou
Hello everyone, I have the following problem: I have a data.frame with multiple fields. If I had to do my calculations for a given combination of IM.type and Taxonomy is the following: D <- read.csv('Test_v2.csv') names(D) VC <- 0.01*( subset(D, IM.type == 'PGA' & Damage.state == 'DS1' &

[R] FW: How to create a new data.frame based on calculation of subsets of an existing data.frame

2019-12-17 Thread Ioanna Ioannou
Hello everyone, I have the following problem: I have a data.frame with multiple fields. If I had to do my calculations for a given combination of IM.type and Taxonomy is the following: D <- read.csv('Test_v2.csv') names(D) VC <- 0.01*( subset(D, IM.type == 'PGA' & Damage.state == 'DS1' &