用给定值更改单元格的范围

问题描述

谁能解决这个问题

google sheet fetch google finance and find SMA

如果 J1 9 ,我需要找到一个简单的移动平均线,然后必须根据 E2:E10 进行计算并放入在 G10

google sheet fetch google finance and find SMA

如果给定值为 15 ,则结果必须持续15个周期SMA

在更改SMA值的同时,必须更改范围并得出给定的SMA

解决方法

您可以使用以下公式:

=IF(ROW()=$J$1+1,AVERAGE($A$2:INDEX(A:A,$J$1+1)),"")

enter image description here