# encoding: ascii
# api: powershell
# title: Get-GrowthRate
# description: Calculates percentage growth rate given a starting value, ending value, and number of periods in the range.  @stahler thx!
# version: 0.1
# type: function
# author: Stahler
# license: CC0
# function: Get-GrowthRate
# x-poshcode-id: 702
# x-archived: 2009-01-06T15:37:28
#
#
function Get-GrowthRate {
	param( $Start, $End, $Period ) 
	$rate = [math]::Abs( [math]::Pow( ( $End / $Start ),( 1 / ( $Period - 1 ) ) ) - 1 )
	"{0:P}" -f $rate
}
