我目前有一个类似于此的数据文件:1 A1 0 0 3 A1 4 8 5 A2 3 3 我想编写一个脚本,它只在"ID“匹配的情况下才能从上一行计算"(8-4)/(4-2)”。例如,在第3行中的列"C“的输出中,如果"ID”列中的A1 == A1,则(8-4)/(4-2) = 2,如果A1 != A1,则输出为0。我希望产出是这样的:
R ID A B C
., \nin accordance with iso 9001 (8-4, 8-2), the regular implementation of"stri_extract_all_fixedglobally expanding its engineering plastics centered on polycarbonate resin
[2] accordance with iso 9001 (8-