10 Replies Latest reply: Dec 28, 2015 7:23 AM by Joshua Solomon

# RE:Ratio

Hi all,

I need to calucalte the raio between

Frmulae: Onsite Hours/Offshore Hours

Dim:Period

sample data lik dis

 year period on_0ff_flag total_hrs total_amt 2011 Per10 Onsite 152 456 2011 Per10 Onsite 152 456 2011 Per10 Onsite 72 216 2011 Per10 Offshore 152 304 2011 Per10 Offshore 152 304 2011 Per10 Offshore 8 16 2011 Per10 Offshore 142 284

how can i achve dis?

thanks

Suresh

• ###### Re: RE:Ratio

Maybe with an expression like

=Sum({<on_0ff_flag = {'Onsite'}>} total_hrs) / Sum({<on_0ff_flag = {'Offshore'}>} total_hrs)

• ###### Re: RE:Ratio

Try as swuehl suggested, then in number tab, select show in percent(%)

• ###### Re: RE:Ratio

thnx swuel..

but i need  from total count of offshre and onsite.....

example:

onsite  :376/830

in 830  total offshre +onsite...

how can i?

• ###### Re: RE:Ratio

Try this:

=Sum({<on_0ff_flag = {'Onsite'}>} total_hrs)/Sum(total_hrs)

• ###### Re: RE:Ratio

Maybe just like

=Sum({<on_0ff_flag = {'Onsite'}>} total_hrs) / Sum(total_hrs)

for onsite and

=Sum({<on_0ff_flag = {'Offshore'}>} total_hrs) / Sum(total_hrs)

for offshore.

• ###### Re: RE:Ratio

thanx swuehl...

this is

=Sum({<onsite_offshore_flag = {'Onsite'}>} total_hrs)/Sum({<onsite_offshore_flag = {'Offshore'}>} total_hrs)&'%'

wat i used but in textbox  it is shwng 0.3191850594%

how to show  in 2digits lik  31%..?

• ###### Re: RE:Ratio

try like this:

=num(Sum({<onsite_offshore_flag = {'Onsite'}>} total_hrs)/Sum({<onsite_offshore_flag = {'Offshore'}>} total_hrs)*100,'#.##')&'%'

• ###### Re: RE:Ratio

this as well:

=num(Sum({<onsite_offshore_flag = {'Onsite'}>} total_hrs)/Sum({<onsite_offshore_flag = {'Offshore'}>} total_hrs)*100,'0')&'%'

• ###### Re: RE:Ratio

Try this

=Num(Sum({<onsite_offshore_flag = {'Onsite'}>} total_hrs)/Sum({<onsite_offshore_flag = {'Offshore'}>} total_hrs), '##.00%')

• ###### Re: RE:Ratio

Hi try this

=SUM({\$< on_off_flag={Onsite}>}total_hrs) /SUM({\$< on_off_flag={Offshore}>}total_hrs)