diff --git a/.nerual_network.cpp.swp b/.nerual_network.cpp.swp index 67bb936f954924567b0493e6e293530c6a8b74e6..9b419884d9f4c940545888c5f305144ce041d139 100644 Binary files a/.nerual_network.cpp.swp and b/.nerual_network.cpp.swp differ diff --git a/README.md b/README.md index 92759d175a748a01a7de6523a5a7bcb5e05f7ee7..a74b92c498ee1b13671f2bff3ac35d6272f51b08 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,3 @@ - -
# Edge-Engine @@ -78,6 +76,8 @@ Matrix API: - [x] Matrix read_csv(string &file_path)读取格式化文件(csv),返回一个自动计算长度的矩阵. +- [x] int save_txt(Matrix mid1,string path = "./",string delimiter = ",",string header="./") 设计文件流获取文件头部接口 , 写入格式化文件 , 已设计支持矩阵类型数据写入,支持自定义表头,写入文件路径 , 自定义分隔符,默认为" , ". + - [x] Create a matrix : create(row,cols)开辟一个矩阵结构的内存,元素初值为0; - [x] Change the element for matrix void move_ele(int &ele1, int &ele2),修改某一个位置的元素的值. diff --git a/.main.cpp.swp b/file_pro/.data_read.h.swp similarity index 75% rename from .main.cpp.swp rename to file_pro/.data_read.h.swp index c41425e242a2983640d7f990968bcd257fef83d5..b356949317ba4c74f5242bcec5f6d3f65d08d8c5 100644 Binary files a/.main.cpp.swp and b/file_pro/.data_read.h.swp differ diff --git a/file_pro/data_read.h b/file_pro/data_read.h index 283897bc81e35a8fdb2d922ecc320ea4f63f15cb..2142f09961158dd8e9dd0ff2fac4228b27deddce 100644 --- a/file_pro/data_read.h +++ b/file_pro/data_read.h @@ -95,4 +95,21 @@ Matrix read_csv(string &file_path) } return data_ma; } +int save_txt(Matrix mid1,string path = "./",string delimiter = ",",string header="./") +{ + int index_x,index_y; + ofstream fout(path,ios::app); + fout<