-
Notifications
You must be signed in to change notification settings - Fork 1
/
pnl.txt
44 lines (31 loc) · 1.62 KB
/
pnl.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
How to use the Profit & Loss Google Docs macro:
===============================================
. Log into your GLBSE account.
. Export your GLBSE data. You should get a file called 'account_history.csv'
. Go and create a new spreadsheet document in Google Docs
. In the newly created spreadsheet, go to Menu->File->Import...
. Press 'Choose file' button and select the previously downloaded file 'account_history.csv'
. Make sure to select the 'Insert new sheet(s)' radio button
. Press the 'Import' button. This should get you a spreadsheet with a sheet called 'account_history'
. Rename that sheet 'Import'
. Go to Menu->Tools->Script Editor
. A new window open that lets you edit code
. Delete all of the existing code in there and paste the code found in file pnl.js
. Press the 'Save' button above the code (the stylized floppy disk icon)
. In the small drop menu above the code, select the 'onOpen' function
. Press the 'Run' button (stylized '>')
At this point, you can go back to your spreadsheet window,
you should see a new menu entry called 'Scripts' in there.
Go to : Menu->Scripts->'P&L Calculator'
Watch it operate (it is not particularly fast, but gets the job done).
Once it has finished, a new sheet called 'PNL' should have appeared in
your spreadsheet that contains a per-ticker summary of what happened in
your account.
Next time around:
. Delete sheet 'Import'
. Re-do the CSV import
. Rename sheet 'account_history' to 'Import'
. Just re-run the script.
Improvements and tips at 1ZnortsoStC1zSTXbW6CUtkvqew8czMMG are welcome
Enjoy
- Znort987