This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namespace_author = "Owen Price"; | |
namespace_author_url = "https://www.flexyourdata.com"; | |
namespace_description="This namespace provides functionality for building depreciation schedules"; | |
schedule_demo = depn.schedule(100000,10000,6,2015,depn.db,true,depn.byyear,true); | |
schedule_header = {"Period labels","Periods","Depreciation","Accumulated Depreciation","Depreciated Asset Value"}; | |
/* | |
Author: Owen Price | |
https://www.flexyourdata.com |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// video explaining all these formulas: https://youtu.be/yO8zX_Ivcug | |
// see video: https://youtu.be/P8knGhzV7uk | |
ListTable = LAMBDA(array, | |
LET(one,TAKE(array,,1),two,TAKE(array,,-1), | |
list,UNIQUE(one), | |
HSTACK(list,BYROW(list,LAMBDA(x,TEXTJOIN(", ",TRUE,FILTER(two,one=x))))))); | |
// see video: https://youtu.be/lli7MTilTB8 | |
repeatXtimes = LAMBDA(array,num_repeat, |