wbhrbb=DynamicModule​​{​​mtRent,​​gsi,​​esc,​​exp,​​val,(*startwithrjbvalmidpoint*)​​k,(*termpriorto1stoptioninyears*)​​r,(*hurdlerateforIRR*)​​rt,(*IRR*)​​llShare,​​output​​​​},​​​​(*Initialvaluesforvariables*)​​exp=.35;​​esc=.025;​​gsi=190500;​​mtRent=97500.;​​k=10;​​r=.05;​​val=3710700;​​​​output[]:=Module​​{​​wbhVal,​​wbhDebt,​​wbhEq,​​rbbVal,​​noi,​​cr,​​npv​​},​​addr={"191 Monroe","4824 Siesta","4816 Siesta","4820 Siesta","4947 Luna","4949 Luna","4948 Luna"};​​rent={2650,2100,2300,2200,2200,2250,2175};​​indVal={515000,403000,463400,473000,457000,460000,475000};​​indDebt={266550,0,204650,0,0,0,245605};​​wbhPmt={1143.76,0,878.17,0,0,0,1293.15};​​tots=Join[{"Total"},Total[#]&/@{rent,wbhPmt,indVal,indDebt,indVal-indDebt}];​​titles={"Address","Rent","Mtg Pmt","indVal","Debt","Equity"};​​Transpose[{addr,rent,wbhPmt,indVal,indDebt,indVal-indDebt(*,tots*)}];​​sched=Grid[Join[{titles},Transpose[{addr,rent,wbhPmt,indVal,indDebt,indVal-indDebt}],{tots}],Frame->All];​​​​rbbVal=4175000;​​llShare=
mtRent
gsi
;​​noi=(1-exp)gsi;​​cr=
noi
val
;​​npv[escl_,gsi_,share_,pval_,r_,k_]:=
k-1
∑
n=1
n-1
(1+escl)
gsishare
n
(1+r)
+
k-1
(1+escl)
pval+
k-1
(1+escl)
gsishare
k
(1+r)
-pval;​​rt=Quiet[Solve[npv[esc,gsi,llShare,val,rate,k]==0,rate,Assumptions->{rate>0,Reals}]][[1,1,2]];​​​​Print[sched];​​​​Print[StringJoin[{"The present capitalization rate is ",ToString[100cr]<>"%"}]];​​​​Print[StringJoin[{"The Landlord's share of cashflow is ",ToString[llShare]}]];​​​​Print[StringJoin[{"The Landlord's NPV is ",ToString[npv[esc,gsi,llShare,val,r,k]]}]];​​​​Print[StringJoin[{"The Landlord's IRR is ",ToString[rt]}]];​​​​;​​​​Column[{​​"Current Value (halfway point)",​​InputField[Dynamic[val],Number,BackgroundWhite],​​​​"Expense-Vac Ratio",​​InputField[Dynamic[exp],Number,BackgroundWhite],​​​​"Annual Escalation",​​InputField[Dynamic[esc],Number,BackgroundWhite],​​​​"Master Tenant Rent",​​InputField[Dynamic[mtRent],Number,BackgroundWhite],​​​​"Min Lease Term (to 1st Option Date)",​​InputField[Dynamic[k],Number,BackgroundWhite],​​​​"Present Gross Income",​​InputField[Dynamic[gsi],Number,BackgroundWhite],​​​​"Hurdle Rate",​​InputField[Dynamic[r],Number,BackgroundWhite],​​​​Button["Submit",output[]]​​},​​​​Alignment{Left},​​ItemStyleDirective[FontFamily"Ariel",FontWeightPlain,FontSize11],​​DividersAll,​​Spacings{.9,.5},​​Background{{LightGray,White}}]​​​​
Out[]=
Current Value (halfway point)
3710700
Expense-Vac Ratio
0.35`
Annual Escalation
0.025`
Master Tenant Rent
97500`
Min Lease Term (to 1st Option Date)
10
Present Gross Income
190500
Hurdle Rate
0.05`
Submit
In[]:=
(*CloudDeploy[wbhrbb,Permissions"Public"]*)