Skip to content

Latest commit

 

History

History
70 lines (48 loc) · 3.97 KB

README.md

File metadata and controls

70 lines (48 loc) · 3.97 KB

Python Native Function(s) in Excel

GitHub Issues GitHub Forks GitHub Stars LICENSE File

Python Native Functions (py2excel) is a set of native MS Excel functions derived/inspired from PyPI modules. The functions are written in pure macros/VBA to be used inside a macro-enabled workbook or can be used as add-ins by saving the files and importing them from the File > Options > Add-Ins tab.

Modules / Add-Ins

The modules/add-ins are available in two formats - scripts and add-ins. The scripts contain scripts and functions in *.vb file format which can be directly added to a macro-enabled workbook/worksheet as per preference. However, it is recommended to either add the contents of the *.vb in the "Personal Workspace" or directly import the codes using add-ins from the created files.

Fiscal Year

The project is inspired by the `fiscalyear`` library hosted in PyPI. The script provides ready-made functions to users who want to convert dates to and from the calendar to the financial year and vice-versa. The following functions/methods are available:

Function: fiscalYear | Release Date 21-05-2024

function-script ms-excel-addins function-example

Parameter Name Accepted Type Optional Parameter Default Value Parameter Definition
value DATE Current Year
prefix STRING "F.Y. " Prefix to be added at the beginning of the resolved finanicial year.
fmt STRING "YYYY" Returns the year in YYYY or YY format depending upon user-preference.
quarter BOOLEAN FALSE Returns the quarter number for the financial year.

Calculator Functions

The project is intended to provide easy-to-use calculations like fixed deposit, recurring deposit, etc. calculator as an MS Excel plugin. Simply integrate the same as add-ins as mentioned. The following functions are available:

Function: fixedDeposit | Release Date 29-06-2024

function-script ms-excel-addins

Parameter Name Accepted Type Optional Parameter Default Value Parameter Definition
principal VARIANT Principal Amount, i.e. A/C Opening Balance
rate VARIANT The (expected) rate of interest. Rate of interest can be either between 0-1 representing actual value, or 0-100 i.e., percentage.
period VARIANT Time period, in years/
type_ STRING "C" {C : Compound Interest, S : Simple Interest}
type_ STRING "Q" {M : Monthly Compunded, Q : Quarterly Compunded, Y : Yearly Compunded}