0
我想看看管道可能是有用的在這裏 -R中與管道更換值
p3Data[which(p3Data$memCond==1), "blockType"] <- 0
p3Data[which(p3Data$memCond==2), "blockType"] <- 0
p3Data[which(p3Data$memCond==3), "blockType"] <- 1
p3Data[which(p3Data$memCond==4), "blockType"] <- 1
p3Data[which(p3Data$memCond==1), "trialType"] <- 0
p3Data[which(p3Data$memCond==2), "trialType"] <- 1
p3Data[which(p3Data$memCond==3), "trialType"] <- 0
p3Data[which(p3Data$memCond==4), "trialType"] <- 1
如何使用%>%,使這更有效率?