I use to write the datas in dat files anfd i would like to close then i have to create the second dat file, writing the datas with particular variable(constant for each .dat files) and that constant value has to be attached as the name of the dat file.
For example, variale is 1,2,3,4,5. I have to create 1.dat then i ll write other x and corresponding y for that variable 1. then i have to close 1.dat . Then this process has to continue for the remain variables say 1,3,4,5. Dat files will be with the name of variable_1.dat , variable_2.dat. variable_3.dat. variable_4.dat. variable_5.dat