There's more to experience when you log in!
Hi,Can anyone please help with Log calc in MIP (Or Discover) from Native/X fileI have looked under Table | SQL; Table | Update Column and Home | Tool Manger | SQL, plus a quick search on the internet
I did try Home | Tool Manger | SQL however, was unable to sort out scripting. I did find the Log function however, I didn't structure the script correct (attached)
In the end, I have to work out side of MIP, and calc in ioGAS, SPSS, Excel or R (prefer to keep inside MIP if at all possible).
Select Au_ppb, Log(Au_ppb)
Perfect, it worked. Thank you Peter
Is there a way to write the LogAu, back to the original table, placing the Log(Au_ppb) at the end of the original table?
I take it you could also apply logs to all e.g. elements in the table, in 1 step?
The results don't look correct? These look to be LN, not log 10 (x). I checked a couple on my calculator and the results in MIP are not Log 10 (x)
Results I'm getting are different to what I'm expecting Peter. My mistake if I didn't specify Log 10 (x) = Log
Thank you, yes it worked (great) and the update column (intersects) also worked.
I will advise the Discover Support who stated on Friday that the Log (10) cannot be calculated in MapInfo.
Appreciate your help once again!
Mike Woodbury – SensOre
As mentioned, your suggestion for calc the log base 10 of my Au ppb works using; Au_ppb, Log(Au_ppb)/Log(10)
I'm just confused, as the equations implies the division by Log (10) [Log (10) = 1], so I was unsure how MIP is calculating the correct value = Ln/1
Yes, Log Base-10. I have included some examples of Au ppb column and the MIP syntax from Friday
The calc/results in MIP are correct;
(Au_ppb)/Log(10) = 2.70805/ 2.3026 (log of 10) = 1.17609 [Log-10 (15)
If MIP could please add in functionality for Log-10 this would be v. helpful
Thank you for your help Peter!
Log(Au_ppb) / Log(10)
Yes please!! Please add a function that we can specify the base as a second parameter, perhaps into one of the functions in the query setup.
The MapBasic log() function is for natural (base e) logs. You can confirm this by taking the log of e itself, which should yield 1.
To find the log of another base, such as 10, simply divide the natural log of your number by the natural log of the desired base.
Hopefully these match both your calculator and your expectations!
In you're working in Python, the math module has log2(x), log10(x) and log(x, base) functions.