- added full portfolio rebalance (33% each slice):
- when one of the slices (algos) switches the risk on/off mode
- one a year
- added plotting of the fractions of each slice in portfolio
- some minor refactoring
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
function main() { | |
int data_feed = FROM_YAHOO ; | |
// int data_feed = FROM_STOOQ ; | |
data_feed |= OVERRIDE ; | |
assetHistory("SPY",data_feed); | |
History = "*una.t6"; | |
assetHistory("SPY",data_feed|UNADJUSTED); |
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
package jforex; | |
import com.dukascopy.api.*; | |
import java.io.File; | |
import java.io.FileOutputStream; | |
import java.io.FileWriter; | |
import java.io.IOException; | |
import java.io.OutputStream; | |
import java.io.OutputStreamWriter; | |
import java.io.Writer; |
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
import random | |
total=1000000 | |
in_circle=0 | |
for i in range(total): | |
(x,y)= (random.random(), random.random()) | |
if x**2 + y**2 <= 1: | |
in_circle+=1 | |
4*(in_circle/total) |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Ever wanted a quick shell cmd to get docker images running in your Kuberentes pods?
Here is one using JQ
$ kgimg
[
{
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
import javafx.util.Pair; | |
import org.testng.annotations.Test; | |
import java.util.*; | |
import static org.testng.Assert.*; | |
public class Sol { | |
static Set<Map<Integer, Integer>> indexPointers(String s) { | |
Set<Map<Integer, Integer>> result = new HashSet<>(); |
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
1 |
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
global | |
maxconn 4096 | |
#debug | |
#quiet | |
defaults | |
mode http | |
option httplog | |
option dontlognull | |
retries 3 |
NewerOlder