PC Review


Reply
Thread Tools Rate Thread

Access 2003 functions

 
 
crhiggins
Guest
Posts: n/a
 
      15th Jan 2008
I am trying to calculate a geometric mean in a report. Access does not have a
geometric mean function. I can do it using common logarithims and
anitlogarithims, but I can only find a natural logarithim function and an exp
function that also is based on natural logs. Without going into excel, does
anybody have any suggestions?

Thanks

Chris
 
Reply With Quote
 
 
 
 
Krzysztof Pozorek [MVP]
Guest
Posts: n/a
 
      15th Jan 2008

Użytkownik "crhiggins" <(E-Mail Removed)> napisał w
wiadomości news:A7BF21FF-F298-4983-8C03-(E-Mail Removed)...
>I am trying to calculate a geometric mean in a report. Access does not have
>a
> geometric mean function. I can do it using common logarithims and
> anitlogarithims, but I can only find a natural logarithim function and an
> exp
> function that also is based on natural logs. Without going into excel,
> does
> anybody have any suggestions?
>


You can write own function for common logarithim (basing on natural
logarithm):

Public Function Log10(Num)
Log10 = Log(Num) / Log(10)
End Function

K.P.


 
Reply With Quote
 
Douglas J. Steele
Guest
Posts: n/a
 
      15th Jan 2008
Yes, the Log function returns the natural log. However, you can calculate
base-n logarithms for any number x by dividing the natural logarithm of x by
the natural logarithm of n as follows:

Logn(x) = Log(x) / Log(n)

The following example from the Help file illustrates a custom Function that
calculates base-10 logarithms:

Function Log10(X As Double) As Double
Log10 = Log(X) / Log(10#)
End Function

To get the inverse of Log10, you'd simply use the ^ operator to raise 10 to
the power of the exponent:

Function Exp10(X As Double) As Double
Exp10 = 10# ^X
End Function

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(no e-mails, please!)


"crhiggins" <(E-Mail Removed)> wrote in message
news:A7BF21FF-F298-4983-8C03-(E-Mail Removed)...
>I am trying to calculate a geometric mean in a report. Access does not have
>a
> geometric mean function. I can do it using common logarithims and
> anitlogarithims, but I can only find a natural logarithim function and an
> exp
> function that also is based on natural logs. Without going into excel,
> does
> anybody have any suggestions?
>
> Thanks
>
> Chris



 
Reply With Quote
 
crhiggins
Guest
Posts: n/a
 
      15th Jan 2008
Thank you for your help. It is very much appreciated.

"crhiggins" wrote:

> I am trying to calculate a geometric mean in a report. Access does not have a
> geometric mean function. I can do it using common logarithims and
> anitlogarithims, but I can only find a natural logarithim function and an exp
> function that also is based on natural logs. Without going into excel, does
> anybody have any suggestions?
>
> Thanks
>
> Chris

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Functions worked in Access 2003 but not in Access 2007 Tom C Microsoft Access Macros 4 16th Aug 2008 12:37 AM
Access 2003 treats embedded functions in nested queries as a reference rather than a value - Access 2007? jgfaughnan Microsoft Access Queries 2 9th Jun 2007 08:16 PM
Functions in Access 2000 not in Access 2003 mcl Microsoft Access Queries 3 5th Jan 2006 03:57 PM
Functions In Access 2003 Jeff Microsoft Access Database Table Design 1 12th Jun 2004 07:38 PM
Functions in Access 2003 David Harris Microsoft Access Reports 1 25th Mar 2004 04:35 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 05:39 PM.