工具
serenahxr
珞珈山厨神
展开
-
调整csv文件格式的时候可能用到的工具
Sub Adj()num = ActiveSheet.UsedRange.Rows.Count()For i = 1 To num If Left(Cells(i, 1), 2) = " " Then Cells(i - 1, 1) = Cells(i - 1, 1) & Trim(Cells(i, 1)) Rows(i).Delete i = i - 1 End If NextEnd Sub众所周知,c.原创 2020-08-11 14:25:27 · 265 阅读 · 0 评论 -
VBA删掉某列中含有空值的行
Sub Del()num = ActiveSheet.UsedRange.Rows.Count()For i = 1 To num If Cells(i, 9) = "" Then Rows(i).Delete End If NextEnd Sub原创 2020-06-09 16:44:31 · 2764 阅读 · 0 评论 -
package ‘rgdal’ is not available (for R version 3.3.3)
解决方法:手动下载1.3.9版本的rgadl到本地后安装install.packages("/Users/Downloads/rgdal_1.3-9.tar.gz", repos=NULL)历史版本下载地址:https://cran.r-project.org/src/contrib/Archive/rgdal/...原创 2020-04-26 10:15:35 · 4100 阅读 · 1 评论 -
使用python对数据进行随机抽样
点名表扬pandasimport pandas as pdfrom openpyxl import workbookimport osimport chardetos.chdir('/Users/huangxinran/Desktop') #输出文件的路径file="/Users/huangxinran/Desktop/1234.csv" #输入的数据文件with open(f...原创 2020-03-17 23:09:16 · 2698 阅读 · 0 评论 -
VLookUP函数在VBA中的语法
Sub VLOOKUP()On Error Resume NextFor i = 2 To 4072 Cells(i, 27) = WorksheetFunction.VLOOKUP(Cells(i, 1), Range("X2:Y6382"), 2, False) NextEnd Sub行数和列数依然可以用ActiveSheet.UsedRange.*系列函数自动读取...原创 2020-02-18 13:32:48 · 2747 阅读 · 0 评论 -
使用VBA进行最大最小值标准化
Sub dataProcess()num = ActiveSheet.UsedRange.Rows.CountOn Error Resume NextFor j = 3 To 20 Max = WorksheetFunction.Max(Range(Cells(2, j), Cells(4072, j))) Min = WorksheetFunction.Min(Range...原创 2020-02-18 13:20:26 · 1395 阅读 · 0 评论