- ·上一篇教育:excel表格中怎么用函数算乘法
- ·下一篇教育:excel表格怎么将折线图冻结
固有频率怎么在excel表格算
1.excel怎么算频率
首先我假设你的数据在A1中.结果分别显示在B1,C1,D1中.
按下ALT+F11,复制下列代码.然后按下F5运行即可
Sub AAAA()
Dim A As Integer
Dim B As Integer
Dim C As Integer
Dim D As Integer
Range("A1").Select
D = Len(Selection)
For X = 1 To D
If Mid(Selection, X, 1) = "A" Then
A = A + 1
Else
If Mid(Selection, X, 1) = "B" Then
B = B + 1
Else
If Mid(Selection, X, 1) = "C" Then
C = C + 1
End If
End If
End If
Next
Range("B1").Select
ActiveCell.Value = "A:" & A &; "个"
Range("C1").Select
ActiveCell.Value = "B:" & B &; "个"
Range("D1").Select
ActiveCell.Value = "C:" & C &; "个"
End Sub
评论内容只代表网友观点,与本站立场无关!
评论摘要(共 0 条,得分 0 分,平均 0 分)