ªð¦^¦Cªí ¤W¤@¥DÃD µo©«

¥i¥H¦bfunction¤¤¥t¨â­Ó°}¦C¤¤ªº­È¬Û´î

¥i¥H¦bfunction¤¤¥t¨â­Ó°}¦C¤¤ªº­È¬Û´î

½Ð°Ý¤@¤U¦U¦ì«e½ú

§Ú·Q¼g¤@­Ófunction , input¤¤¦³¨â­Ó¬OarrayA ©M arrayB  , ¨ä¤¤arrayA ¬O·|§ïÅܪº ,arrayB¬O©T©wªº

¦bfunction¸Ì§Ú·Q­nÅýarrayA - arrayB ¦¨¬°¤@­ÓÅÜ¼Æ arrayC , ¶i¦Ó¹ï arrayC ¨D¥­§¡  ¦ý¤£ª¾¨ì­þÃä¥X¤F¿ù?

ªþ¤W§Úªºµ{¦¡½X½Ð¤j®aÀ°§Ú¬Ý¤@¤U  ÁÂÁÂÅo

§Ú¼gªºfunction¬O module1 ¸Ìªº TrkErr  

Test.rar (23.44 KB)

arrayA - arrayB ¦¨¬°¤@­ÓÅÜ¼Æ arrayC , ¶i¦Ó¹ï arrayC ¨D¥­§¡
ldneye µoªí©ó 2013-11-28 09:59

¬Ý¤£À´TrkErr¥\¯à

§A»¡ arrayA - arrayB ¦¨¬° arrayC
¨º¨DarrayC ¥­§¡ = arrayA¥­§¡ - arrayB¥­§¡ ´N¦n¤F°Ú

TOP

FN = Arr.Count

     For x = 1 To FN
        ReDim Crr(x)
        Crr(x) = Arr(x) - Brr(x)
     Next
{...} ªí¥Ü»Ý­n¥Î CTRL+SHIFT+ENTER ¤TÁä¿é¤J¤½¦¡

TOP

3#¤£¹ï REDIM ¤£¯à¦b°j°é¸Ì

    FN = Arr.Count

     ReDim Crr(x)
    For x = 1 To FN
        Crr(x) = Arr(x) - Brr(x)
     Next
{...} ªí¥Ü»Ý­n¥Î CTRL+SHIFT+ENTER ¤TÁä¿é¤J¤½¦¡

TOP

¥»©«³Ì«á¥Ñ ML089 ©ó 2013-11-29 17:58 ½s¿è

Function TrkErr(Arr As Range, Brr As Range, FN As Integer) As Double

    Dim avg As Single, SumSq As Single    ', Crr As Range
    Dim i As Range
    'FN ¬Oloopªº¦¸¼Æ ¤]¬O¾ã­Ó¸ê®Æªºrows -1 ;
    '¦]¬°§Ú¨S¦³§ó¦nªº¤èªk¥i¥Hª½±µ¦bfunction¸Ì¨D ©Ò¥H§ï¬°input
    '¦pªG¦³§ó¦nªº¤èªk¤]½Ð§iª¾  ÁÂÁ­ò

    FN = Arr.Count
    ReDim Crr(FN)
    For x = 1 To Arr.Count
        Crr(x) = Arr(x) - Brr(x)
    Next


    ' Brr¬O©T©wªº  Arr¬O¤£¦Pªº¤½¥q

    avg = WorksheetFunction.Average(Crr)


    For Each i In Arr
        SumSq = SumSq + (i - avg) ^ 2
    Next i

    FN = Arr.Count
    TrkErr = Sqr(SumSq / (FN - 1))

End Function
{...} ªí¥Ü»Ý­n¥Î CTRL+SHIFT+ENTER ¤TÁä¿é¤J¤½¦¡

TOP

³o¬O¥t¤@ºØ½m²ß¼gªk¡A½Ð°Ñ¦Ò

Function TrkErr(Arr As Range, Brr As Range, FN As Integer) As Double
    Dim avg As Single, SumSq As Single
    FN = Arr.Count
    Crr = Application.Evaluate(Arr.Address & "-" & Brr.Address)
    avg = WorksheetFunction.Average(Crr)

    For Each i In Arr
        SumSq = SumSq + (i - avg) ^ 2
    Next i
    TrkErr = Sqr(SumSq / (FN - 1))
End Function
{...} ªí¥Ü»Ý­n¥Î CTRL+SHIFT+ENTER ¤TÁä¿é¤J¤½¦¡

TOP

¦^´_ 2# stillfish00


    ÁÂÁ¡A³o­Ó¤èªk§Ú¤@®É¨S¦³·Q¨ì  ¥H«á·|°O¦íªº°Õ  ·PÁ­ò

TOP

¦^´_ 6# ML089


    ÁÂÁÂML¤j  §Ú¸Õ¤F§Aªº¨â­Ó¤èªk  ³£¨S¿ìªk¶]  ®Ú¾Ú§ÚÀˬdªºµ²ªG  µ{¦¡Á`¬O¦b Set AP = Range(Cells(k, 3), Cells(k, 14))  ³o¦æ¶]¤£¹L¥h  ¤£ª¾¹D³o¼Ëªº¼gªk¬O¦³¤°»ò°ÝÃD¶Ü??

TOP

¦^´_ 8# ldneye


    »yªk¨S¦³¿ù»~
À³¸Ó¬O k ¨S¦³­È©Î¬°0©Ò­P¡A½Ð³]¤¤Â_ÂI¤Î«öF8³v±ø¬d¬Ý k ªºÅܤÆ
{...} ªí¥Ü»Ý­n¥Î CTRL+SHIFT+ENTER ¤TÁä¿é¤J¤½¦¡

TOP

¦^´_ 9# ML089


  ÁÂÁ§Aªº¦^ÂР §ÚÀˬd¤F¤@¤U  ¬O§Ú¦³­Ócells ±q¹s¶}©l¤F  @@   ¤£¦n·N«äªü

TOP

        ÀR«ä¦Û¦b : ¶¢¤HµL¼Ö½ì¡A¦£¤HµL¬O«D¡C
ªð¦^¦Cªí ¤W¤@¥DÃD