Support » Plugin: TablePress » Formulas in tables
Formulas in tables

Hi.
Is it possible to put FORMULAS on tables?
I can’t find information about this feature.

Hi,
yes, as briefly mentioned on the plugin website, you can have formulas, similar to those in Excel, in your table. I haven’t yet had the time to thoroughly document this, but it’s pretty much straight forward:
Here are two basic examples:=A1+B3
will sum the cells A1 and B3.
=AVERAGE(C3:C10)
will calculate the average value of the cells from C3 through C10.
Regards,
TobiasThank you.
Any sheet with all available formulas on your website?Hi,
no, there’s no such sheet yet, as I just didn’t have the time yet 🙁 Sorry. But I like the idea, and I will try to create a list for the documentation!
However, here’s a list of the available math functions, that I directly extracted from the plugin’s source code. Maybe that is helpful for now.
sin, sinh, arcsin, asin, arcsinh, asinh, cos, cosh, arccos, acos, arccosh, acosh, tan, tanh, arctan, atan, arctanh, atanh, sqrt, abs, ln, log, exp, floor, ceil, average, max, min, mod, pi, power, round, sum, rand_int, rand_float
Best wishes,
TobiasThank you in advance.
I love this plugin, I gave you 5 stars!
Keep good work!Hi,
thank you, that’s very nice! I really appreciate it!
Best wishes,
TobiasTobias,
Thank you for providing the above examples. The examples are very helpful. I have tablepress on my silver website. I need to insert a more complicated mathematical formula. Based on the information you provided, it will look something like this:
=C2 x .925 x .90 x (silver spot price)
I have two issues:
1. The table does not perform multiplication. The following error is displayed:
“!ERROR! expecting operator, implicit multiplication not allowed.”
2. I need the formula to calculate the current price of silver. I cannot enter a set amount (for example, 28.89). The price of silver changes constantly.
Is there a way to input the price of silver from the following code:
<object width=”336″ height=”180″>
<param name=”movie” value=”http://www.monex.com/ichart/inter_chart.swf” />
<embed src=”http://www.monex.com/ichart/inter_chart.swf” width=”336″ height=”180″>
</embed>
</object>The above code is from Monex.com. It provides the current price for silver, gold, platinum, and palladium.
Hi,
thanks for your question.
First: No, importing the price from an external source is not possible. I suggest that you designate a special cell in the table that holds the price, which you manually update (I will assume you choose cell A4).
With that, the formula in the cell would become
=C2*0.925*0.90*A4
Regards,
TobiasOne other issue. The chart only recognizes whole numbers when computing mathematical equations. I need it to recognize decimals as well.
Thanks for your response and suggestion about a separate column for spot price. This may be the best temporary solution.
Hi,
it will recognize decimals, but only if you use the dot
.
as the decimal separator, instead of a comma,
. If you need the,
for visual purposes, I suggest to create a second (hidden) column with the same data, but different decimal separators.Regards,
TobiasI am not using any commas. I only use dots. But it still show up as an error.
I am using the following formula to calculate silver melt value:
=C2*0.925*0.90*E2
!ERROR! C2 does not contain a number or expression 28.84
Hi,
it looks like there’s a space after the 82.11. Could you check that?
(Could catch by the way, I’ll see if I can make the formula parser ignore such spaces. The best way is to not have them though.)Regards,
TobiasIt works! Thank you so much. I deleted the space. Now I have two other issues. Is there a way to add a dollar sign in column D and E without throwing off the code. Also, is there a way to only display two digits after the decimal point instead of 6 digits. For example,
the final product in column D should look like this:$1971.40
 The topic ‘Formulas in tables’ is closed to new replies.