D3
OG
Old school D3 from simpler times
All examples
By author
By category
About
dukevis
Full window
Github gist
sexual disorder streamgraph
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <link href="nv.d3.css" rel="stylesheet" type="text/css"> <script src="https://cdnjs.cloudflare.com/ajax/libs/d3/3.5.2/d3.min.js" charset="utf-8"></script> <script src="nv.d3.js"></script> <script src="colorbrewer.js"></script> <style> text { font: 12px sans-serif; } svg { display: block; } html, body, svg { margin: 0px; padding: 0px; height: 100%; width: 100%; } </style> </head> <!--body class='with-3d-shadow with-transitions'--> <body> <svg id="chart1"></svg> <script> var sexual_data = "category,date,val\nfemale only: female arousal disorder,1946,0.00000000000000000\nfemale only: female arousal disorder,1948,0.00000000000000000\nfemale only: female arousal disorder,1950,0.00000000000000000\nfemale only: female arousal disorder,1951,0.00000000000000000\nfemale only: female arousal disorder,1952,0.00000000000000000\nfemale only: female arousal disorder,1953,0.00000000000000000\nfemale only: female arousal disorder,1954,0.00000000000000000\nfemale only: female arousal disorder,1959,0.00000000000000000\nfemale only: female arousal disorder,1961,0.00000000000000000\nfemale only: female arousal disorder,1962,0.00000000000000000\nfemale only: female arousal disorder,1963,0.00000000000000000\nfemale only: female arousal disorder,1964,0.00000000000000000\nfemale only: female arousal disorder,1965,0.00000000000000000\nfemale only: female arousal disorder,1966,0.00000000000000000\nfemale only: female arousal disorder,1967,0.00000000000000000\nfemale only: female arousal disorder,1968,0.00000000000000000\nfemale only: female arousal disorder,1969,0.00000000000000000\nfemale only: female arousal disorder,1970,0.00000000000000000\nfemale only: female arousal disorder,1971,0.00000000000000000\nfemale only: female arousal disorder,1972,0.00000000000000000\nfemale only: female arousal disorder,1973,0.00000000000000000\nfemale only: female arousal disorder,1974,0.00000000000000000\nfemale only: female arousal disorder,1975,0.00000000000000000\nfemale only: female arousal disorder,1976,0.00000000000000000\nfemale only: female arousal disorder,1977,0.00000000000000000\nfemale only: female arousal disorder,1978,0.00000000000000000\nfemale only: female arousal disorder,1979,0.00000000000000000\nfemale only: female arousal disorder,1980,0.00000000000000000\nfemale only: female arousal disorder,1981,0.00000000000000000\nfemale only: female arousal disorder,1982,0.00000000000000000\nfemale only: female arousal disorder,1983,0.00034861425832317\nfemale only: female arousal disorder,1984,0.00000000000000000\nfemale only: female arousal disorder,1985,0.00015260186174271\nfemale only: female arousal disorder,1986,0.00000000000000000\nfemale only: female arousal disorder,1987,0.00000000000000000\nfemale only: female arousal disorder,1988,0.00012425447316103\nfemale only: female arousal disorder,1989,0.00000000000000000\nfemale only: female arousal disorder,1990,0.00000000000000000\nfemale only: female arousal disorder,1991,0.00000000000000000\nfemale only: female arousal disorder,1992,0.00000000000000000\nfemale only: female arousal disorder,1993,0.00000000000000000\nfemale only: female arousal disorder,1994,0.00000000000000000\nfemale only: female arousal disorder,1995,0.00000000000000000\nfemale only: female arousal disorder,1996,0.00000000000000000\nfemale only: female arousal disorder,1997,0.00008787346221441\nfemale only: female arousal disorder,1998,0.00000000000000000\nfemale only: female arousal disorder,1999,0.00008166598611678\nfemale only: female arousal disorder,2000,0.00015326844968963\nfemale only: female arousal disorder,2001,0.00021788074660469\nfemale only: female arousal disorder,2002,0.00034373710985838\nfemale only: female arousal disorder,2003,0.00031452475309807\nfemale only: female arousal disorder,2004,0.00000000000000000\nfemale only: female arousal disorder,2005,0.00000000000000000\nfemale only: female arousal disorder,2006,0.00039856516540454\nfemale only: female arousal disorder,2007,0.00009470593806232\nfemale only: female arousal disorder,2008,0.00008948545861298\nfemale only: female arousal disorder,2009,0.00030491788996820\nfemale only: female arousal disorder,2010,0.00037367656217563\nfemale only: female arousal disorder,2011,0.00011970313622217\nfemale only: female arousal disorder,2012,0.00003742935209792\nfemale only: female arousal disorder,2013,0.00024163344206838\nfemale only: female arousal disorder,2014,0.00000000000000000\nfemale only: female sexual dysfunction,1946,0.00000000000000000\nfemale only: female sexual dysfunction,1948,0.00000000000000000\nfemale only: female sexual dysfunction,1950,0.00000000000000000\nfemale only: female sexual dysfunction,1951,0.00000000000000000\nfemale only: female sexual dysfunction,1952,0.00000000000000000\nfemale only: female sexual dysfunction,1953,0.00000000000000000\nfemale only: female sexual dysfunction,1954,0.00000000000000000\nfemale only: female sexual dysfunction,1959,0.00000000000000000\nfemale only: female sexual dysfunction,1961,0.00000000000000000\nfemale only: female sexual dysfunction,1962,0.00000000000000000\nfemale only: female sexual dysfunction,1963,0.00000000000000000\nfemale only: female sexual dysfunction,1964,0.00000000000000000\nfemale only: female sexual dysfunction,1965,0.00000000000000000\nfemale only: female sexual dysfunction,1966,0.00000000000000000\nfemale only: female sexual dysfunction,1967,0.00000000000000000\nfemale only: female sexual dysfunction,1968,0.00000000000000000\nfemale only: female sexual dysfunction,1969,0.00000000000000000\nfemale only: female sexual dysfunction,1970,0.00000000000000000\nfemale only: female sexual dysfunction,1971,0.00000000000000000\nfemale only: female sexual dysfunction,1972,0.00000000000000000\nfemale only: female sexual dysfunction,1973,0.00000000000000000\nfemale only: female sexual dysfunction,1974,0.00000000000000000\nfemale only: female sexual dysfunction,1975,0.00027754648903691\nfemale only: female sexual dysfunction,1976,0.00000000000000000\nfemale only: female sexual dysfunction,1977,0.00025660764690788\nfemale only: female sexual dysfunction,1978,0.00024521824423737\nfemale only: female sexual dysfunction,1979,0.00022517451024544\nfemale only: female sexual dysfunction,1980,0.00000000000000000\nfemale only: female sexual dysfunction,1981,0.00019623233908948\nfemale only: female sexual dysfunction,1982,0.00000000000000000\nfemale only: female sexual dysfunction,1983,0.00017430712916158\nfemale only: female sexual dysfunction,1984,0.00000000000000000\nfemale only: female sexual dysfunction,1985,0.00000000000000000\nfemale only: female sexual dysfunction,1986,0.00000000000000000\nfemale only: female sexual dysfunction,1987,0.00000000000000000\nfemale only: female sexual dysfunction,1988,0.00012425447316103\nfemale only: female sexual dysfunction,1989,0.00000000000000000\nfemale only: female sexual dysfunction,1990,0.00011431184270690\nfemale only: female sexual dysfunction,1991,0.00011500862564692\nfemale only: female sexual dysfunction,1992,0.00011116051578479\nfemale only: female sexual dysfunction,1993,0.00000000000000000\nfemale only: female sexual dysfunction,1994,0.00000000000000000\nfemale only: female sexual dysfunction,1995,0.00000000000000000\nfemale only: female sexual dysfunction,1996,0.00009384384384384\nfemale only: female sexual dysfunction,1997,0.00026362038664323\nfemale only: female sexual dysfunction,1998,0.00025942580421999\nfemale only: female sexual dysfunction,1999,0.00024499795835035\nfemale only: female sexual dysfunction,2000,0.00038317112422408\nfemale only: female sexual dysfunction,2001,0.00203355363497712\nfemale only: female sexual dysfunction,2002,0.00178743297126358\nfemale only: female sexual dysfunction,2003,0.00050323960495691\nfemale only: female sexual dysfunction,2004,0.00080985711806560\nfemale only: female sexual dysfunction,2005,0.00115600572498073\nfemale only: female sexual dysfunction,2006,0.00059784774810682\nfemale only: female sexual dysfunction,2007,0.00071029453546737\nfemale only: female sexual dysfunction,2008,0.00062639821029083\nfemale only: female sexual dysfunction,2009,0.00087119397133772\nfemale only: female sexual dysfunction,2010,0.00099647083246834\nfemale only: female sexual dysfunction,2011,0.00059851568111085\nfemale only: female sexual dysfunction,2012,0.00052401092937081\nfemale only: female sexual dysfunction,2013,0.00060408360517096\nfemale only: female sexual dysfunction,2014,0.00086095566078347\nfemale only: premenstrual dysphoric disorder,1946,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1948,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1950,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1951,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1952,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1953,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1954,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1959,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1961,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1962,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1963,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1964,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1965,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1966,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1967,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1968,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1969,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1970,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1971,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1972,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1973,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1974,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1975,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1976,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1977,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1978,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1979,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1980,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1981,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1982,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1983,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1984,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1985,0.00015260186174271\nfemale only: premenstrual dysphoric disorder,1986,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1987,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1988,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1989,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1990,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1991,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1992,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1993,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1994,0.00000000000000000\nfemale only: premenstrual dysphoric disorder,1995,0.00030630998570553\nfemale only: premenstrual dysphoric disorder,1996,0.00075075075075075\nfemale only: premenstrual dysphoric disorder,1997,0.00052724077328647\nfemale only: premenstrual dysphoric disorder,1998,0.00043237634036666\nfemale only: premenstrual dysphoric disorder,1999,0.00065332788893426\nfemale only: premenstrual dysphoric disorder,2000,0.00038317112422408\nfemale only: premenstrual dysphoric disorder,2001,0.00101677681748856\nfemale only: premenstrual dysphoric disorder,2002,0.00061872679774509\nfemale only: premenstrual dysphoric disorder,2003,0.00025161980247846\nfemale only: premenstrual dysphoric disorder,2004,0.00046277549603749\nfemale only: premenstrual dysphoric disorder,2005,0.00033028734999450\nfemale only: premenstrual dysphoric disorder,2006,0.00004982064567557\nfemale only: premenstrual dysphoric disorder,2007,0.00033147078321811\nfemale only: premenstrual dysphoric disorder,2008,0.00044742729306488\nfemale only: premenstrual dysphoric disorder,2009,0.00030491788996820\nfemale only: premenstrual dysphoric disorder,2010,0.00029063732613660\nfemale only: premenstrual dysphoric disorder,2011,0.00023940627244434\nfemale only: premenstrual dysphoric disorder,2012,0.00029943481678332\nfemale only: premenstrual dysphoric disorder,2013,0.00028190568241311\nfemale only: premenstrual dysphoric disorder,2014,0.00000000000000000\nfemale only: vaginismus,1946,0.00000000000000000\nfemale only: vaginismus,1948,0.00000000000000000\nfemale only: vaginismus,1950,0.00000000000000000\nfemale only: vaginismus,1951,0.00000000000000000\nfemale only: vaginismus,1952,0.00000000000000000\nfemale only: vaginismus,1953,0.00104602510460251\nfemale only: vaginismus,1954,0.00000000000000000\nfemale only: vaginismus,1959,0.00000000000000000\nfemale only: vaginismus,1961,0.00000000000000000\nfemale only: vaginismus,1962,0.00000000000000000\nfemale only: vaginismus,1963,0.00000000000000000\nfemale only: vaginismus,1964,0.00000000000000000\nfemale only: vaginismus,1965,0.00044326241134752\nfemale only: vaginismus,1966,0.00000000000000000\nfemale only: vaginismus,1967,0.00000000000000000\nfemale only: vaginismus,1968,0.00034002040122407\nfemale only: vaginismus,1969,0.00066269052352551\nfemale only: vaginismus,1970,0.00000000000000000\nfemale only: vaginismus,1971,0.00030102347983143\nfemale only: vaginismus,1972,0.00029568302779421\nfemale only: vaginismus,1973,0.00028645087367517\nfemale only: vaginismus,1974,0.00000000000000000\nfemale only: vaginismus,1975,0.00055509297807383\nfemale only: vaginismus,1976,0.00000000000000000\nfemale only: vaginismus,1977,0.00076982294072363\nfemale only: vaginismus,1978,0.00073565473271211\nfemale only: vaginismus,1979,0.00022517451024544\nfemale only: vaginismus,1980,0.00043744531933508\nfemale only: vaginismus,1981,0.00000000000000000\nfemale only: vaginismus,1982,0.00018433179723502\nfemale only: vaginismus,1983,0.00000000000000000\nfemale only: vaginismus,1984,0.00032943501894251\nfemale only: vaginismus,1985,0.00015260186174271\nfemale only: vaginismus,1986,0.00000000000000000\nfemale only: vaginismus,1987,0.00000000000000000\nfemale only: vaginismus,1988,0.00037276341948310\nfemale only: vaginismus,1989,0.00023510050546609\nfemale only: vaginismus,1990,0.00000000000000000\nfemale only: vaginismus,1991,0.00011500862564692\nfemale only: vaginismus,1992,0.00011116051578479\nfemale only: vaginismus,1993,0.00000000000000000\nfemale only: vaginismus,1994,0.00030509508796908\nfemale only: vaginismus,1995,0.00020420665713702\nfemale only: vaginismus,1996,0.00018768768768769\nfemale only: vaginismus,1997,0.00017574692442882\nfemale only: vaginismus,1998,0.00008647526807333\nfemale only: vaginismus,1999,0.00008166598611678\nfemale only: vaginismus,2000,0.00015326844968963\nfemale only: vaginismus,2001,0.00058101532427918\nfemale only: vaginismus,2002,0.00006874742197168\nfemale only: vaginismus,2003,0.00025161980247846\nfemale only: vaginismus,2004,0.00040492855903280\nfemale only: vaginismus,2005,0.00022019156666300\nfemale only: vaginismus,2006,0.00014946193702670\nfemale only: vaginismus,2007,0.00018941187612463\nfemale only: vaginismus,2008,0.00013422818791946\nfemale only: vaginismus,2009,0.00052271638280263\nfemale only: vaginismus,2010,0.00033215694415611\nfemale only: vaginismus,2011,0.00023940627244434\nfemale only: vaginismus,2012,0.00022457611258749\nfemale only: vaginismus,2013,0.00016108896137892\nfemale only: vaginismus,2014,0.00000000000000000\nmale only: delayed ejaculation,1946,0.00000000000000000\nmale only: delayed ejaculation,1948,0.00000000000000000\nmale only: delayed ejaculation,1950,0.00000000000000000\nmale only: delayed ejaculation,1951,0.00000000000000000\nmale only: delayed ejaculation,1952,0.00000000000000000\nmale only: delayed ejaculation,1953,0.00000000000000000\nmale only: delayed ejaculation,1954,0.00000000000000000\nmale only: delayed ejaculation,1959,0.00000000000000000\nmale only: delayed ejaculation,1961,0.00000000000000000\nmale only: delayed ejaculation,1962,0.00000000000000000\nmale only: delayed ejaculation,1963,0.00000000000000000\nmale only: delayed ejaculation,1964,0.00000000000000000\nmale only: delayed ejaculation,1965,0.00000000000000000\nmale only: delayed ejaculation,1966,0.00000000000000000\nmale only: delayed ejaculation,1967,0.00000000000000000\nmale only: delayed ejaculation,1968,0.00000000000000000\nmale only: delayed ejaculation,1969,0.00000000000000000\nmale only: delayed ejaculation,1970,0.00000000000000000\nmale only: delayed ejaculation,1971,0.00000000000000000\nmale only: delayed ejaculation,1972,0.00000000000000000\nmale only: delayed ejaculation,1973,0.00000000000000000\nmale only: delayed ejaculation,1974,0.00000000000000000\nmale only: delayed ejaculation,1975,0.00000000000000000\nmale only: delayed ejaculation,1976,0.00000000000000000\nmale only: delayed ejaculation,1977,0.00000000000000000\nmale only: delayed ejaculation,1978,0.00000000000000000\nmale only: delayed ejaculation,1979,0.00000000000000000\nmale only: delayed ejaculation,1980,0.00000000000000000\nmale only: delayed ejaculation,1981,0.00000000000000000\nmale only: delayed ejaculation,1982,0.00000000000000000\nmale only: delayed ejaculation,1983,0.00000000000000000\nmale only: delayed ejaculation,1984,0.00000000000000000\nmale only: delayed ejaculation,1985,0.00000000000000000\nmale only: delayed ejaculation,1986,0.00000000000000000\nmale only: delayed ejaculation,1987,0.00000000000000000\nmale only: delayed ejaculation,1988,0.00000000000000000\nmale only: delayed ejaculation,1989,0.00000000000000000\nmale only: delayed ejaculation,1990,0.00000000000000000\nmale only: delayed ejaculation,1991,0.00000000000000000\nmale only: delayed ejaculation,1992,0.00000000000000000\nmale only: delayed ejaculation,1993,0.00000000000000000\nmale only: delayed ejaculation,1994,0.00000000000000000\nmale only: delayed ejaculation,1995,0.00000000000000000\nmale only: delayed ejaculation,1996,0.00000000000000000\nmale only: delayed ejaculation,1997,0.00008787346221441\nmale only: delayed ejaculation,1998,0.00000000000000000\nmale only: delayed ejaculation,1999,0.00000000000000000\nmale only: delayed ejaculation,2000,0.00000000000000000\nmale only: delayed ejaculation,2001,0.00000000000000000\nmale only: delayed ejaculation,2002,0.00000000000000000\nmale only: delayed ejaculation,2003,0.00006290495061961\nmale only: delayed ejaculation,2004,0.00000000000000000\nmale only: delayed ejaculation,2005,0.00000000000000000\nmale only: delayed ejaculation,2006,0.00004982064567557\nmale only: delayed ejaculation,2007,0.00009470593806232\nmale only: delayed ejaculation,2008,0.00004474272930649\nmale only: delayed ejaculation,2009,0.00004355969856689\nmale only: delayed ejaculation,2010,0.00004151961801951\nmale only: delayed ejaculation,2011,0.00000000000000000\nmale only: delayed ejaculation,2012,0.00007485870419583\nmale only: delayed ejaculation,2013,0.00004027224034473\nmale only: delayed ejaculation,2014,0.00000000000000000\nmale only: erectile dysfunction,1946,0.00000000000000000\nmale only: erectile dysfunction,1948,0.00000000000000000\nmale only: erectile dysfunction,1950,0.00000000000000000\nmale only: erectile dysfunction,1951,0.00000000000000000\nmale only: erectile dysfunction,1952,0.00000000000000000\nmale only: erectile dysfunction,1953,0.00000000000000000\nmale only: erectile dysfunction,1954,0.00000000000000000\nmale only: erectile dysfunction,1959,0.00000000000000000\nmale only: erectile dysfunction,1961,0.00000000000000000\nmale only: erectile dysfunction,1962,0.00000000000000000\nmale only: erectile dysfunction,1963,0.00000000000000000\nmale only: erectile dysfunction,1964,0.00000000000000000\nmale only: erectile dysfunction,1965,0.00000000000000000\nmale only: erectile dysfunction,1966,0.00000000000000000\nmale only: erectile dysfunction,1967,0.00000000000000000\nmale only: erectile dysfunction,1968,0.00000000000000000\nmale only: erectile dysfunction,1969,0.00000000000000000\nmale only: erectile dysfunction,1970,0.00000000000000000\nmale only: erectile dysfunction,1971,0.00000000000000000\nmale only: erectile dysfunction,1972,0.00000000000000000\nmale only: erectile dysfunction,1973,0.00000000000000000\nmale only: erectile dysfunction,1974,0.00000000000000000\nmale only: erectile dysfunction,1975,0.00000000000000000\nmale only: erectile dysfunction,1976,0.00026659557451346\nmale only: erectile dysfunction,1977,0.00051321529381576\nmale only: erectile dysfunction,1978,0.00049043648847474\nmale only: erectile dysfunction,1979,0.00067552353073632\nmale only: erectile dysfunction,1980,0.00109361329833771\nmale only: erectile dysfunction,1981,0.00176609105180534\nmale only: erectile dysfunction,1982,0.00202764976958525\nmale only: erectile dysfunction,1983,0.00139445703329266\nmale only: erectile dysfunction,1984,0.00049415252841377\nmale only: erectile dysfunction,1985,0.00091561117045628\nmale only: erectile dysfunction,1986,0.00206440957886045\nmale only: erectile dysfunction,1987,0.00176056338028169\nmale only: erectile dysfunction,1988,0.00447316103379722\nmale only: erectile dysfunction,1989,0.00340895732925826\nmale only: erectile dysfunction,1990,0.00331504343850023\nmale only: erectile dysfunction,1991,0.00379528464634848\nmale only: erectile dysfunction,1992,0.00377945753668297\nmale only: erectile dysfunction,1993,0.00427537820653365\nmale only: erectile dysfunction,1994,0.00640699684735076\nmale only: erectile dysfunction,1995,0.00816826628548091\nmale only: erectile dysfunction,1996,0.00534909909909910\nmale only: erectile dysfunction,1997,0.00702987697715290\nmale only: erectile dysfunction,1998,0.01297129021099970\nmale only: erectile dysfunction,1999,0.01306655777868520\nmale only: erectile dysfunction,2000,0.01586328454287680\nmale only: erectile dysfunction,2001,0.01583266758660760\nmale only: erectile dysfunction,2002,0.01835556166643750\nmale only: erectile dysfunction,2003,0.01950053469208030\nmale only: erectile dysfunction,2004,0.02030427488864460\nmale only: erectile dysfunction,2005,0.02091819883298470\nmale only: erectile dysfunction,2006,0.01718812275807090\nmale only: erectile dysfunction,2007,0.01387441992612940\nmale only: erectile dysfunction,2008,0.01458612975391500\nmale only: erectile dysfunction,2009,0.01263231258439690\nmale only: erectile dysfunction,2010,0.01083662030309320\nmale only: erectile dysfunction,2011,0.01029446971510650\nmale only: erectile dysfunction,2012,0.01010592506643710\nmale only: erectile dysfunction,2013,0.01067214369135350\nmale only: erectile dysfunction,2014,0.00774860094705123\nmale only: male sexual dysfunction,1946,0.00000000000000000\nmale only: male sexual dysfunction,1948,0.00000000000000000\nmale only: male sexual dysfunction,1950,0.00000000000000000\nmale only: male sexual dysfunction,1951,0.00000000000000000\nmale only: male sexual dysfunction,1952,0.00000000000000000\nmale only: male sexual dysfunction,1953,0.00000000000000000\nmale only: male sexual dysfunction,1954,0.00000000000000000\nmale only: male sexual dysfunction,1959,0.00000000000000000\nmale only: male sexual dysfunction,1961,0.00000000000000000\nmale only: male sexual dysfunction,1962,0.00000000000000000\nmale only: male sexual dysfunction,1963,0.00000000000000000\nmale only: male sexual dysfunction,1964,0.00000000000000000\nmale only: male sexual dysfunction,1965,0.00000000000000000\nmale only: male sexual dysfunction,1966,0.00000000000000000\nmale only: male sexual dysfunction,1967,0.00000000000000000\nmale only: male sexual dysfunction,1968,0.00000000000000000\nmale only: male sexual dysfunction,1969,0.00000000000000000\nmale only: male sexual dysfunction,1970,0.00000000000000000\nmale only: male sexual dysfunction,1971,0.00000000000000000\nmale only: male sexual dysfunction,1972,0.00000000000000000\nmale only: male sexual dysfunction,1973,0.00000000000000000\nmale only: male sexual dysfunction,1974,0.00000000000000000\nmale only: male sexual dysfunction,1975,0.00027754648903691\nmale only: male sexual dysfunction,1976,0.00026659557451346\nmale only: male sexual dysfunction,1977,0.00051321529381576\nmale only: male sexual dysfunction,1978,0.00049043648847474\nmale only: male sexual dysfunction,1979,0.00067552353073632\nmale only: male sexual dysfunction,1980,0.00065616797900263\nmale only: male sexual dysfunction,1981,0.00039246467817896\nmale only: male sexual dysfunction,1982,0.00129032258064516\nmale only: male sexual dysfunction,1983,0.00069722851664633\nmale only: male sexual dysfunction,1984,0.00098830505682754\nmale only: male sexual dysfunction,1985,0.00076300930871357\nmale only: male sexual dysfunction,1986,0.00041288191577209\nmale only: male sexual dysfunction,1987,0.00054171180931744\nmale only: male sexual dysfunction,1988,0.00062127236580517\nmale only: male sexual dysfunction,1989,0.00035265075819913\nmale only: male sexual dysfunction,1990,0.00034293552812071\nmale only: male sexual dysfunction,1991,0.00080506037952847\nmale only: male sexual dysfunction,1992,0.00000000000000000\nmale only: male sexual dysfunction,1993,0.00032887524665644\nmale only: male sexual dysfunction,1994,0.00040679345062545\nmale only: male sexual dysfunction,1995,0.00030630998570553\nmale only: male sexual dysfunction,1996,0.00046921921921922\nmale only: male sexual dysfunction,1997,0.00026362038664323\nmale only: male sexual dysfunction,1998,0.00025942580421999\nmale only: male sexual dysfunction,1999,0.00040832993058391\nmale only: male sexual dysfunction,2000,0.00045980534906889\nmale only: male sexual dysfunction,2001,0.00036313457767449\nmale only: male sexual dysfunction,2002,0.00041248453183006\nmale only: male sexual dysfunction,2003,0.00044033465433730\nmale only: male sexual dysfunction,2004,0.00040492855903280\nmale only: male sexual dysfunction,2005,0.00060552680832324\nmale only: male sexual dysfunction,2006,0.00044838581108011\nmale only: male sexual dysfunction,2007,0.00033147078321811\nmale only: male sexual dysfunction,2008,0.00017897091722595\nmale only: male sexual dysfunction,2009,0.00052271638280263\nmale only: male sexual dysfunction,2010,0.00070583350633174\nmale only: male sexual dysfunction,2011,0.00035910940866651\nmale only: male sexual dysfunction,2012,0.00026200546468541\nmale only: male sexual dysfunction,2013,0.00028190568241311\nmale only: male sexual dysfunction,2014,0.00000000000000000\nmale only: premature ejaculation,1946,0.00534759358288770\nmale only: premature ejaculation,1948,0.00000000000000000\nmale only: premature ejaculation,1950,0.00000000000000000\nmale only: premature ejaculation,1951,0.00000000000000000\nmale only: premature ejaculation,1952,0.00000000000000000\nmale only: premature ejaculation,1953,0.00104602510460251\nmale only: premature ejaculation,1954,0.00000000000000000\nmale only: premature ejaculation,1959,0.00000000000000000\nmale only: premature ejaculation,1961,0.00000000000000000\nmale only: premature ejaculation,1962,0.00000000000000000\nmale only: premature ejaculation,1963,0.00054377379010332\nmale only: premature ejaculation,1964,0.00000000000000000\nmale only: premature ejaculation,1965,0.00000000000000000\nmale only: premature ejaculation,1966,0.00000000000000000\nmale only: premature ejaculation,1967,0.00000000000000000\nmale only: premature ejaculation,1968,0.00068004080244815\nmale only: premature ejaculation,1969,0.00033134526176276\nmale only: premature ejaculation,1970,0.00032467532467533\nmale only: premature ejaculation,1971,0.00000000000000000\nmale only: premature ejaculation,1972,0.00029568302779421\nmale only: premature ejaculation,1973,0.00000000000000000\nmale only: premature ejaculation,1974,0.00000000000000000\nmale only: premature ejaculation,1975,0.00000000000000000\nmale only: premature ejaculation,1976,0.00000000000000000\nmale only: premature ejaculation,1977,0.00000000000000000\nmale only: premature ejaculation,1978,0.00024521824423737\nmale only: premature ejaculation,1979,0.00067552353073632\nmale only: premature ejaculation,1980,0.00021872265966754\nmale only: premature ejaculation,1981,0.00019623233908948\nmale only: premature ejaculation,1982,0.00000000000000000\nmale only: premature ejaculation,1983,0.00000000000000000\nmale only: premature ejaculation,1984,0.00049415252841377\nmale only: premature ejaculation,1985,0.00000000000000000\nmale only: premature ejaculation,1986,0.00027525461051473\nmale only: premature ejaculation,1987,0.00027085590465872\nmale only: premature ejaculation,1988,0.00049701789264414\nmale only: premature ejaculation,1989,0.00000000000000000\nmale only: premature ejaculation,1990,0.00000000000000000\nmale only: premature ejaculation,1991,0.00011500862564692\nmale only: premature ejaculation,1992,0.00022232103156959\nmale only: premature ejaculation,1993,0.00032887524665644\nmale only: premature ejaculation,1994,0.00040679345062545\nmale only: premature ejaculation,1995,0.00061261997141107\nmale only: premature ejaculation,1996,0.00037537537537538\nmale only: premature ejaculation,1997,0.00026362038664323\nmale only: premature ejaculation,1998,0.00043237634036666\nmale only: premature ejaculation,1999,0.00000000000000000\nmale only: premature ejaculation,2000,0.00022990267453445\nmale only: premature ejaculation,2001,0.00000000000000000\nmale only: premature ejaculation,2002,0.00027498968788670\nmale only: premature ejaculation,2003,0.00062904950619614\nmale only: premature ejaculation,2004,0.00023138774801874\nmale only: premature ejaculation,2005,0.00082571837498624\nmale only: premature ejaculation,2006,0.00104623355918693\nmale only: premature ejaculation,2007,0.00108911828771664\nmale only: premature ejaculation,2008,0.00076062639821029\nmale only: premature ejaculation,2009,0.00056627608136952\nmale only: premature ejaculation,2010,0.00062279427029271\nmale only: premature ejaculation,2011,0.00091772404436996\nmale only: premature ejaculation,2012,0.00093573380244788\nmale only: premature ejaculation,2013,0.00116789496999718\nmale only: premature ejaculation,2014,0.00086095566078347\nneutral gender: disorders of sex development,1946,0.00000000000000000\nneutral gender: disorders of sex development,1948,0.00000000000000000\nneutral gender: disorders of sex development,1950,0.00000000000000000\nneutral gender: disorders of sex development,1951,0.00000000000000000\nneutral gender: disorders of sex development,1952,0.00000000000000000\nneutral gender: disorders of sex development,1953,0.00000000000000000\nneutral gender: disorders of sex development,1954,0.00000000000000000\nneutral gender: disorders of sex development,1959,0.00000000000000000\nneutral gender: disorders of sex development,1961,0.00154798761609907\nneutral gender: disorders of sex development,1962,0.00000000000000000\nneutral gender: disorders of sex development,1963,0.00000000000000000\nneutral gender: disorders of sex development,1964,0.00046168051708218\nneutral gender: disorders of sex development,1965,0.00177304964539007\nneutral gender: disorders of sex development,1966,0.00208942749686586\nneutral gender: disorders of sex development,1967,0.00113981762917933\nneutral gender: disorders of sex development,1968,0.00204012240734444\nneutral gender: disorders of sex development,1969,0.00298210735586481\nneutral gender: disorders of sex development,1970,0.00649350649350649\nneutral gender: disorders of sex development,1971,0.00511739915713426\nneutral gender: disorders of sex development,1972,0.00384387936132466\nneutral gender: disorders of sex development,1973,0.00229160698940132\nneutral gender: disorders of sex development,1974,0.00334914875802400\nneutral gender: disorders of sex development,1975,0.00305301137940605\nneutral gender: disorders of sex development,1976,0.00319914689416156\nneutral gender: disorders of sex development,1977,0.00333589940980241\nneutral gender: disorders of sex development,1978,0.00220696419813634\nneutral gender: disorders of sex development,1979,0.00247691961269984\nneutral gender: disorders of sex development,1980,0.00262467191601050\nneutral gender: disorders of sex development,1981,0.00137362637362637\nneutral gender: disorders of sex development,1982,0.00221198156682028\nneutral gender: disorders of sex development,1983,0.00052292138748475\nneutral gender: disorders of sex development,1984,0.00164717509471257\nneutral gender: disorders of sex development,1985,0.00106821303219899\nneutral gender: disorders of sex development,1986,0.00055050922102945\nneutral gender: disorders of sex development,1987,0.00108342361863489\nneutral gender: disorders of sex development,1988,0.00099403578528827\nneutral gender: disorders of sex development,1989,0.00035265075819913\nneutral gender: disorders of sex development,1990,0.00057155921353452\nneutral gender: disorders of sex development,1991,0.00046003450258769\nneutral gender: disorders of sex development,1992,0.00166740773677190\nneutral gender: disorders of sex development,1993,0.00076737557553168\nneutral gender: disorders of sex development,1994,0.00040679345062545\nneutral gender: disorders of sex development,1995,0.00051051664284256\nneutral gender: disorders of sex development,1996,0.00065690690690691\nneutral gender: disorders of sex development,1997,0.00026362038664323\nneutral gender: disorders of sex development,1998,0.00077827741265998\nneutral gender: disorders of sex development,1999,0.00040832993058391\nneutral gender: disorders of sex development,2000,0.00061307379875853\nneutral gender: disorders of sex development,2001,0.00043576149320938\nneutral gender: disorders of sex development,2002,0.00061872679774509\nneutral gender: disorders of sex development,2003,0.00044033465433730\nneutral gender: disorders of sex development,2004,0.00098339792907966\nneutral gender: disorders of sex development,2005,0.00093581415831774\nneutral gender: disorders of sex development,2006,0.00039856516540454\nneutral gender: disorders of sex development,2007,0.00066294156643622\nneutral gender: disorders of sex development,2008,0.00093959731543624\nneutral gender: disorders of sex development,2009,0.00117611186130592\nneutral gender: disorders of sex development,2010,0.00170230433880008\nneutral gender: disorders of sex development,2011,0.00219455749740643\nneutral gender: disorders of sex development,2012,0.00202118501328742\nneutral gender: disorders of sex development,2013,0.00100680600861826\nneutral gender: disorders of sex development,2014,0.00215238915195867\nneutral gender: gender disorder,1946,0.00000000000000000\nneutral gender: gender disorder,1948,0.00000000000000000\nneutral gender: gender disorder,1950,0.00000000000000000\nneutral gender: gender disorder,1951,0.00000000000000000\nneutral gender: gender disorder,1952,0.00000000000000000\nneutral gender: gender disorder,1953,0.00000000000000000\nneutral gender: gender disorder,1954,0.00000000000000000\nneutral gender: gender disorder,1959,0.00000000000000000\nneutral gender: gender disorder,1961,0.00000000000000000\nneutral gender: gender disorder,1962,0.00000000000000000\nneutral gender: gender disorder,1963,0.00000000000000000\nneutral gender: gender disorder,1964,0.00000000000000000\nneutral gender: gender disorder,1965,0.00000000000000000\nneutral gender: gender disorder,1966,0.00000000000000000\nneutral gender: gender disorder,1967,0.00000000000000000\nneutral gender: gender disorder,1968,0.00000000000000000\nneutral gender: gender disorder,1969,0.00000000000000000\nneutral gender: gender disorder,1970,0.00000000000000000\nneutral gender: gender disorder,1971,0.00030102347983143\nneutral gender: gender disorder,1972,0.00000000000000000\nneutral gender: gender disorder,1973,0.00000000000000000\nneutral gender: gender disorder,1974,0.00111638291934133\nneutral gender: gender disorder,1975,0.00000000000000000\nneutral gender: gender disorder,1976,0.00026659557451346\nneutral gender: gender disorder,1977,0.00076982294072363\nneutral gender: gender disorder,1978,0.00024521824423737\nneutral gender: gender disorder,1979,0.00022517451024544\nneutral gender: gender disorder,1980,0.00087489063867017\nneutral gender: gender disorder,1981,0.00058869701726845\nneutral gender: gender disorder,1982,0.00036866359447005\nneutral gender: gender disorder,1983,0.00034861425832317\nneutral gender: gender disorder,1984,0.00016471750947126\nneutral gender: gender disorder,1985,0.00030520372348543\nneutral gender: gender disorder,1986,0.00000000000000000\nneutral gender: gender disorder,1987,0.00054171180931744\nneutral gender: gender disorder,1988,0.00012425447316103\nneutral gender: gender disorder,1989,0.00035265075819913\nneutral gender: gender disorder,1990,0.00057155921353452\nneutral gender: gender disorder,1991,0.00057504312823462\nneutral gender: gender disorder,1992,0.00022232103156959\nneutral gender: gender disorder,1993,0.00065775049331287\nneutral gender: gender disorder,1994,0.00091528526390725\nneutral gender: gender disorder,1995,0.00091892995711660\nneutral gender: gender disorder,1996,0.00075075075075075\nneutral gender: gender disorder,1997,0.00114235500878735\nneutral gender: gender disorder,1998,0.00060532687651332\nneutral gender: gender disorder,1999,0.00081665986116782\nneutral gender: gender disorder,2000,0.00053643957391371\nneutral gender: gender disorder,2001,0.00072626915534897\nneutral gender: gender disorder,2002,0.00041248453183006\nneutral gender: gender disorder,2003,0.00106938416053343\nneutral gender: gender disorder,2004,0.00069416324405623\nneutral gender: gender disorder,2005,0.00104590994164923\nneutral gender: gender disorder,2006,0.00049820645675568\nneutral gender: gender disorder,2007,0.00094705938062317\nneutral gender: gender disorder,2008,0.00076062639821029\nneutral gender: gender disorder,2009,0.00104543276560526\nneutral gender: gender disorder,2010,0.00145318663068300\nneutral gender: gender disorder,2011,0.00119703136222169\nneutral gender: gender disorder,2012,0.00116030991503537\nneutral gender: gender disorder,2013,0.00096653376827353\nneutral gender: gender disorder,2014,0.00129143349117520\nneutral gender: other disorders,1946,0.00000000000000000\nneutral gender: other disorders,1948,0.00478468899521531\nneutral gender: other disorders,1950,0.00000000000000000\nneutral gender: other disorders,1951,0.00000000000000000\nneutral gender: other disorders,1952,0.00000000000000000\nneutral gender: other disorders,1953,0.00000000000000000\nneutral gender: other disorders,1954,0.00101832993890020\nneutral gender: other disorders,1959,0.00081566068515498\nneutral gender: other disorders,1961,0.00000000000000000\nneutral gender: other disorders,1962,0.00073152889539137\nneutral gender: other disorders,1963,0.00054377379010332\nneutral gender: other disorders,1964,0.00046168051708218\nneutral gender: other disorders,1965,0.00044326241134752\nneutral gender: other disorders,1966,0.00000000000000000\nneutral gender: other disorders,1967,0.00075987841945289\nneutral gender: other disorders,1968,0.00034002040122407\nneutral gender: other disorders,1969,0.00066269052352551\nneutral gender: other disorders,1970,0.00064935064935065\nneutral gender: other disorders,1971,0.00150511739915713\nneutral gender: other disorders,1972,0.00059136605558841\nneutral gender: other disorders,1973,0.00028645087367517\nneutral gender: other disorders,1974,0.00000000000000000\nneutral gender: other disorders,1975,0.00027754648903691\nneutral gender: other disorders,1976,0.00133297787256732\nneutral gender: other disorders,1977,0.00153964588144727\nneutral gender: other disorders,1978,0.00024521824423737\nneutral gender: other disorders,1979,0.00090069804098176\nneutral gender: other disorders,1980,0.00131233595800525\nneutral gender: other disorders,1981,0.00078492935635793\nneutral gender: other disorders,1982,0.00055299539170507\nneutral gender: other disorders,1983,0.00104584277496950\nneutral gender: other disorders,1984,0.00214132762312634\nneutral gender: other disorders,1985,0.00030520372348543\nneutral gender: other disorders,1986,0.00055050922102945\nneutral gender: other disorders,1987,0.00135427952329361\nneutral gender: other disorders,1988,0.00049701789264414\nneutral gender: other disorders,1989,0.00035265075819913\nneutral gender: other disorders,1990,0.00068587105624143\nneutral gender: other disorders,1991,0.00057504312823462\nneutral gender: other disorders,1992,0.00066696309470876\nneutral gender: other disorders,1993,0.00109625082218812\nneutral gender: other disorders,1994,0.00061019017593817\nneutral gender: other disorders,1995,0.00071472329997958\nneutral gender: other disorders,1996,0.00037537537537538\nneutral gender: other disorders,1997,0.00114235500878735\nneutral gender: other disorders,1998,0.00121065375302663\nneutral gender: other disorders,1999,0.00146998775010208\nneutral gender: other disorders,2000,0.00137941604720668\nneutral gender: other disorders,2001,0.00137991139516305\nneutral gender: other disorders,2002,0.00116870617351849\nneutral gender: other disorders,2003,0.00113228911115305\nneutral gender: other disorders,2004,0.00086770405507028\nneutral gender: other disorders,2005,0.00165143674997248\nneutral gender: other disorders,2006,0.00139497807891590\nneutral gender: other disorders,2007,0.00113647125674780\nneutral gender: other disorders,2008,0.00125279642058166\nneutral gender: other disorders,2009,0.00152458944984101\nneutral gender: other disorders,2010,0.00137014739464397\nneutral gender: other disorders,2011,0.00163594286170298\nneutral gender: other disorders,2012,0.00127259797132912\nneutral gender: other disorders,2013,0.00092626152792880\nneutral gender: other disorders,2014,0.00043047783039174\nneutral gender: sexual disorder,1946,0.00000000000000000\nneutral gender: sexual disorder,1948,0.00000000000000000\nneutral gender: sexual disorder,1950,0.00153846153846154\nneutral gender: sexual disorder,1951,0.00117924528301887\nneutral gender: sexual disorder,1952,0.00103519668737060\nneutral gender: sexual disorder,1953,0.00104602510460251\nneutral gender: sexual disorder,1954,0.00000000000000000\nneutral gender: sexual disorder,1959,0.00000000000000000\nneutral gender: sexual disorder,1961,0.00154798761609907\nneutral gender: sexual disorder,1962,0.00146305779078274\nneutral gender: sexual disorder,1963,0.00108754758020663\nneutral gender: sexual disorder,1964,0.00184672206832872\nneutral gender: sexual disorder,1965,0.00177304964539007\nneutral gender: sexual disorder,1966,0.00292519849561220\nneutral gender: sexual disorder,1967,0.00265957446808511\nneutral gender: sexual disorder,1968,0.00102006120367222\nneutral gender: sexual disorder,1969,0.00099403578528827\nneutral gender: sexual disorder,1970,0.00227272727272727\nneutral gender: sexual disorder,1971,0.00180614087898856\nneutral gender: sexual disorder,1972,0.00236546422235364\nneutral gender: sexual disorder,1973,0.00200515611572615\nneutral gender: sexual disorder,1974,0.00362824448785934\nneutral gender: sexual disorder,1975,0.00360810435747988\nneutral gender: sexual disorder,1976,0.00266595574513463\nneutral gender: sexual disorder,1977,0.00256607646907878\nneutral gender: sexual disorder,1978,0.00392349190779794\nneutral gender: sexual disorder,1979,0.00292726863319072\nneutral gender: sexual disorder,1980,0.00524934383202100\nneutral gender: sexual disorder,1981,0.00372841444270016\nneutral gender: sexual disorder,1982,0.00534562211981567\nneutral gender: sexual disorder,1983,0.00348614258323165\nneutral gender: sexual disorder,1984,0.00345906769889639\nneutral gender: sexual disorder,1985,0.00137341675568442\nneutral gender: sexual disorder,1986,0.00289017341040462\nneutral gender: sexual disorder,1987,0.00243770314192849\nneutral gender: sexual disorder,1988,0.00310636182902585\nneutral gender: sexual disorder,1989,0.00246855530739391\nneutral gender: sexual disorder,1990,0.00217192501143118\nneutral gender: sexual disorder,1991,0.00264519838987924\nneutral gender: sexual disorder,1992,0.00311249444197421\nneutral gender: sexual disorder,1993,0.00186362639771980\nneutral gender: sexual disorder,1994,0.00132207871453270\nneutral gender: sexual disorder,1995,0.00234837655707576\nneutral gender: sexual disorder,1996,0.00187687687687688\nneutral gender: sexual disorder,1997,0.00254833040421793\nneutral gender: sexual disorder,1998,0.00259425804219993\nneutral gender: sexual disorder,1999,0.00400163331972234\nneutral gender: sexual disorder,2000,0.00298873476894781\nneutral gender: sexual disorder,2001,0.00254194204372140\nneutral gender: sexual disorder,2002,0.00391860305238554\nneutral gender: sexual disorder,2003,0.00364848713593760\nneutral gender: sexual disorder,2004,0.00283449991322959\nneutral gender: sexual disorder,2005,0.00401849609159969\nneutral gender: sexual disorder,2006,0.00348744519728976\nneutral gender: sexual disorder,2007,0.00312529595605644\nneutral gender: sexual disorder,2008,0.00425055928411633\nneutral gender: sexual disorder,2009,0.00313629829681579\nneutral gender: sexual disorder,2010,0.00323853020552211\nneutral gender: sexual disorder,2011,0.00283297422392467\nneutral gender: sexual disorder,2012,0.00284463075944155\nneutral gender: sexual disorder,2013,0.00318150698723370\nneutral gender: sexual disorder,2014,0.00215238915195867" var new_string_data = d3.csv.parse(sexual_data) console.log(new_string_data) var exampleData = [ ]; // populate the empty object with your data new_string_data.forEach(function (d){ //new_string_data.forEach(function (d){ d.date = +d.date d.val = +d.val var pushed = false; var cat; for (cat in exampleData) { if(exampleData[cat].key == d.category) { //console.log(exampleData) exampleData[cat].values.push([d.date, d.val]) pushed = true; } } if(!pushed) { exampleData.push({key: d.category, values: [[d.date, d.val]]}) } //console.log(d.category) }) console.log(exampleData) //var colors = ["#BE6528", "#D39163", "#054C38", "#1D6D54", "#468E76", "#84BFA9"]; var fem_colors = colorbrewer.Reds[6].slice(1,5) var neut_colors = colorbrewer.Greys[6].slice(1,5) var male_colors = colorbrewer.Blues[6].slice(1,5) var colors = [fem_colors[0], fem_colors[1], fem_colors[2], fem_colors[3], male_colors[0], male_colors[1], male_colors[2], male_colors[3], neut_colors[0], neut_colors[1], neut_colors[2], neut_colors[3]] var chart; nv.addGraph(function() { chart = nv.models.stackedAreaChart() .useInteractiveGuideline(true) .x(function(d) { console.log(d[0]); return d[0] }) .y(function(d) { console.log(d[1]); return d[1] }) //.controlLabels({stacked: "Stacked"}) .color(colors) .showControls(false) .style('stream-center') //.style('stream') .duration(300); //chart.xAxis.tickFormat(function(d) { return d3.time.format('%x')(new Date(d)) }); //chart.xAxis.tickFormat(d3.format(',.2f')); chart.yAxis.tickFormat(d3.format('.01%')); chart.legend.vers('furious') .expanded(false); d3.select('#chart1') .datum(exampleData) .transition().duration(1000) .call(chart) .each('start', function() { setTimeout(function() { d3.selectAll('#chart1 *').each(function() { if(this.__transition__) this.__transition__.duration = 1; }) }, 0) }); nv.utils.windowResize(chart.update); return chart; }); //}); </script> </body> </html>
https://cdnjs.cloudflare.com/ajax/libs/d3/3.5.2/d3.min.js