| 1 | # Chicago Mercantile Exchange setups. | ||
| 2 | |||
| 3 | # Copyright 2005, 2006, 2007, 2008, 2009 Kevin Ryde | ||
| 4 | |||
| 5 | # This file is part of Chart. | ||
| 6 | # | ||
| 7 | # Chart is free software; you can redistribute it and/or modify it under the | ||
| 8 | # terms of the GNU General Public License as published by the Free Software | ||
| 9 | # Foundation; either version 3, or (at your option) any later version. | ||
| 10 | # | ||
| 11 | # Chart is distributed in the hope that it will be useful, but WITHOUT ANY | ||
| 12 | # WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS | ||
| 13 | # FOR A PARTICULAR PURPOSE. See the GNU General Public License for more | ||
| 14 | # details. | ||
| 15 | # | ||
| 16 | # You should have received a copy of the GNU General Public License along | ||
| 17 | # with Chart. If not, see <http://www.gnu.org/licenses/>. | ||
| 18 | |||
| 19 | package App::Chart::Suffix::CME; | ||
| 20 | use strict; | ||
| 21 | use warnings; | ||
| 22 | use Locale::TextDomain 'App-Chart'; | ||
| 23 | |||
| 24 | use App::Chart; | ||
| 25 | use App::Chart::Barchart; | ||
| 26 | use App::Chart::Sympred; | ||
| 27 | use App::Chart::TZ; | ||
| 28 | use App::Chart::Weblink; | ||
| 29 | use App::Chart::Yahoo; | ||
| 30 | |||
| 31 | my $pred = App::Chart::Sympred::Suffix->new ('.CME'); | ||
| 32 | App::Chart::TZ->chicago->setup_for_symbol ($pred); | ||
| 33 | |||
| 34 | $App::Chart::Yahoo::latest_pred->add ($pred); | ||
| 35 | $App::Chart::Barchart::intraday_pred->add ($pred); | ||
| 36 | $App::Chart::Barchart::fiveday_pred->add ($pred); | ||
| 37 | |||
| 38 | |||
| 39 | #------------------------------------------------------------------------------ | ||
| 40 | # weblink - contract specs | ||
| 41 | |||
| 42 | App::Chart::Weblink->new | ||
| 43 | (pred => $pred, | ||
| 44 | name => __('CME _Contract Specifications'), | ||
| 45 | desc => __('Open web browser at the Chicago Mercantile Exchange contract specifications for this commodity'), | ||
| 46 | proc => sub { | ||
| 47 | my ($symbol) = @_; | ||
| 48 | return 'http://www.cme.com/clearing/clr/spec/contract_specifications_cl.html?product=' | ||
| 49 | . URI::Escape::uri_escape (App::Chart::symbol_commodity ($symbol)); | ||
| 50 | }); | ||
| 51 | |||
| 52 | |||
| 53 | #------------------------------------------------------------------------------ | ||
| 54 | |||
| 55 | # (set! barchart-suffix-delay-alist (acons ".CME" 10 | ||
| 56 | # barchart-suffix-delay-alist)) | ||
| 57 | |||
| 58 | |||
| 59 | App::Chart::Barchart::commodity_mung | ||
| 60 | ($pred, | ||
| 61 | # interest rate products (IMM) | ||
| 62 | # "EM" # 1-month LIBOR | ||
| 63 | 'GLB' => 'GH', # 1-month LIBOR electronic | ||
| 64 | 'TB' => undef, # 13-week treasury bills | ||
| 65 | 'GTB' => undef, # 13-week treasury bills electronic | ||
| 66 | # 'S2' # 2-year swap pit+electronic | ||
| 67 | # 'S5' # 5-year swap electronic | ||
| 68 | 'SW5' => undef, # 5-year swap pit | ||
| 69 | # 'S0' # 10-year swap | ||
| 70 | 'SW0' => 'S0', # 10-year swap electronic | ||
| 71 | 'TIE' => 'F3', # 28-day mexican TIIE | ||
| 72 | 'GTI' => 'F4', # 28-day mexican TIIE electronic | ||
| 73 | 'CET' => 'F1', # 91-day mexican CETES | ||
| 74 | 'GCE' => 'F2', # 91-day mexican CETES electronic | ||
| 75 | 'Y5' => undef, # 5-year eurodollar bundle options | ||
| 76 | 'CPI' => 'CI', # consumer price index | ||
| 77 | # 'ED' # eurodollar | ||
| 78 | # 'GE' # eurodollar electronic | ||
| 79 | '3F' => undef, # eurodollar FRA | ||
| 80 | # 'EY' # euroyen | ||
| 81 | # 'EL' # euroyen LIBOR | ||
| 82 | 'TZ' => undef, # fed funds turn | ||
| 83 | # 'JB' # japanese government bonds | ||
| 84 | # (F0, F5 agency swaps delisted 11 Apr 05) | ||
| 85 | |||
| 86 | # equity products | ||
| 87 | # 'NQ' # e-mini nasdaq 100 | ||
| 88 | # 'ES' # e-mini s&p 500 | ||
| 89 | 'EMD' => 'MD', # e-mini s&p 500 | ||
| 90 | 'FIN' => 'PF', # financial spctr | ||
| 91 | # 'GI' # GSCI | ||
| 92 | 'GD' => undef, # GSCI electronic | ||
| 93 | # 'ND' # nasdaq 100 pit+electronic | ||
| 94 | # 'NK' # nikkei 225 dollar | ||
| 95 | 'NKD' => 'NY', # nikkei 225 dollar electronic | ||
| 96 | 'NIY' => 'NL', # nikkei 225 yen electronic | ||
| 97 | 'RS1' => 'RW', # russell 1000 | ||
| 98 | # 'RL' # russell 2000 pit+electronic | ||
| 99 | 'ER2' => 'EZ', # e-mini russell 2000 | ||
| 100 | # 'SP' # s&p 500 | ||
| 101 | # 'SG' # s&p 500 barra growth | ||
| 102 | # 'SU' # s&p 500 barra value | ||
| 103 | # 'MD' # s&p midcap 400 pit+electronic | ||
| 104 | 'SMC' => 'PC', # s&p smallcap 600 electronic | ||
| 105 | 'QCN' => 'NC', # e-mini nasdaq composite pit+elec | ||
| 106 | 'TEC' => 'PT', # technology spctr | ||
| 107 | 'X1' => undef, # X-Funds 1 index | ||
| 108 | 'X2' => undef, # X-Funds 2 index | ||
| 109 | 'X3' => undef, # X-Funds 3 index | ||
| 110 | 'X4' => undef, # X-Funds 4 index | ||
| 111 | 'X5' => undef, # X-Funds 5 index | ||
| 112 | |||
| 113 | # FX products | ||
| 114 | # 'AD' # australian dollar | ||
| 115 | '6A' => 'A6', # australian dollar electronic | ||
| 116 | 'UAC' => 'UG', # AUD/CAND | ||
| 117 | 'ACD' => undef, # AUD/CAND electronic | ||
| 118 | 'UAY' => 'UI', # AUD/NZD | ||
| 119 | 'AJY' => undef, # AUD/NZD electronic | ||
| 120 | 'UAN' => 'UK', # AUD/Yen | ||
| 121 | 'ANE' => undef, # AUD/Yen electronic | ||
| 122 | # 'BR' # brazilian real | ||
| 123 | '6L' => 'L6', # brazilian real electronic | ||
| 124 | # 'BP' # british pound | ||
| 125 | '6B' => 'B6', # british pound electronic | ||
| 126 | 'UPS' => 'UN', # pound/swiss franc | ||
| 127 | 'PSF' => undef, # pound/swiss franc electronic | ||
| 128 | 'UPY' => 'UR', # pound/yen | ||
| 129 | 'PJY' => undef, # pound/yen electronic | ||
| 130 | # 'CD' # canadian dollar | ||
| 131 | '6C' => 'D6', # canadian dollar electronic | ||
| 132 | 'UCY' => 'UF', # canadian/yen | ||
| 133 | 'CJY' => undef, # canadian/yen electronic | ||
| 134 | 'CZK' => 'WC', # czech koruna pit+electronic | ||
| 135 | # 'E7' # e-mini euro | ||
| 136 | # 'J7' # e-mini yen | ||
| 137 | # 'EC' # euro fx | ||
| 138 | '6E' => 'E6', # euro fx electronic | ||
| 139 | 'UEA' => 'UC', # euro/australian | ||
| 140 | 'EAD' => undef, # euro/australian electronic | ||
| 141 | 'UE' => 'RP', # euro/pound | ||
| 142 | # 'RP' # euro/pound electronic | ||
| 143 | 'UEC' => 'UE', # euro/canadian | ||
| 144 | 'ECD' => undef, # euro/canadian electronic | ||
| 145 | 'ECZ' => 'WE', # euro/czech koruna | ||
| 146 | 'ECK' => undef, # euro/czech koruna electronic | ||
| 147 | 'EHU' => 'WU', # euro/hungarian forint | ||
| 148 | 'EHF' => undef, # euro/hungarian forint electronic | ||
| 149 | 'UH' => 'RY', # euro/yen | ||
| 150 | # 'RY' # euro/yen electronic | ||
| 151 | 'UEN' => 'UB', # euro/norwegian krone | ||
| 152 | 'ENK' => undef, # euro/norwegian krone electronic | ||
| 153 | 'EPL' => 'WZ', # euro/polish zloty | ||
| 154 | 'EPZ' => undef, # euro/polish zloty electronic | ||
| 155 | 'UES' => 'UA', # euro/swedish krona | ||
| 156 | 'ESK' => undef, # euro/swedish krona electronic | ||
| 157 | 'UA' => 'RF', # euro/swiss franc | ||
| 158 | # 'RF' # euro/swiss franc electronic | ||
| 159 | 'HFO' => 'WH', # hungarian forint pit+electronic | ||
| 160 | # 'JY' # yen | ||
| 161 | '6J' => 'J6', # yen electronic | ||
| 162 | 'MP' => 'MQ', # mexican peso | ||
| 163 | '6M' => 'M6', # mexican peso electronic | ||
| 164 | # 'NE' # new zealand dollar | ||
| 165 | '6N' => 'N6', # new zealand dollar electronic | ||
| 166 | 'UNK' => 'NR', # norwegian krone | ||
| 167 | 'NOK' => undef, # norwegian krone electronic | ||
| 168 | 'PLZ' => 'WP', # polish zloty | ||
| 169 | 'PLN' => undef, # polish zloty electronic | ||
| 170 | # 'RU' # russian ruble | ||
| 171 | '6R' => 'R6', # russian ruble electronic | ||
| 172 | # 'RA' # south african rand | ||
| 173 | '6Z' => 'T6', # south african rand electronic | ||
| 174 | 'USK' => 'SK', # swedish krona | ||
| 175 | 'SEK' => undef, # swedish krona electronic | ||
| 176 | # 'SF' # swiss franc | ||
| 177 | '6S' => 'S6', # swiss franc electronic | ||
| 178 | 'USY' => 'UP', # swiss franc/yen | ||
| 179 | 'SJY' => undef, # swiss franc/yen electronic | ||
| 180 | |||
| 181 | # commodity products | ||
| 182 | # 'DB' # butter | ||
| 183 | # 'DA' # class III milk | ||
| 184 | # 'DK' # class IV milk | ||
| 185 | # 'FC' # feeder cattle | ||
| 186 | # 'GF' # feeder cattle electronic | ||
| 187 | 'GPB' => 'PD', # pork bellies electronic | ||
| 188 | # 'PB' # frozen pork bellies | ||
| 189 | # 'LH' # lean hogs | ||
| 190 | # 'HE' # lean hogs electronic | ||
| 191 | # 'LC' # live cattle | ||
| 192 | # 'LE' # live cattle electronic | ||
| 193 | 'NF' => 'DF', # non-fat dry milk | ||
| 194 | 'AA' => undef, # spot butter grade AA | ||
| 195 | 'BK' => undef, # spot cheese blocks | ||
| 196 | 'RB' => undef, # spot cheese barrels | ||
| 197 | 'NM' => undef, # spot nonfat dry milk grade A | ||
| 198 | 'NX' => undef, # spot nonfat dry milk extra grade | ||
| 199 | # 'LB' # lumber | ||
| 200 | 'DP' => 'TD', # diammonium phosphate (DAP) | ||
| 201 | 'UL' => 'TL', # ammonium nitrate (UAN) | ||
| 202 | 'UF' => 'TZ', # urea | ||
| 203 | |||
| 204 | # environmental products | ||
| 205 | 'QM' => undef, # NYMEX e-miNY light sweet crude | ||
| 206 | 'QG' => undef, # NYMEX e-miNY natural gas | ||
| 207 | # weather ... | ||
| 208 | |||
| 209 | # TRAKRS Products | ||
| 210 | 'CCC' => undef, # Commodity TRAKRS | ||
| 211 | 'ECT' => undef, # Euro Currency TRAKRS | ||
| 212 | 'GLD' => undef, # Gold TRAKRS | ||
| 213 | 'OOO' => undef, # LMC TRAKRS | ||
| 214 | 'MLT' => undef, # Long-Short Tech TRAKRS | ||
| 215 | 'LST' => undef, # Long-Short Tech TRAKRS III | ||
| 216 | 'TTT' => undef, # Select 50 TRAKRS | ||
| 217 | ); | ||
| 218 | |||
| 219 | |||
| 220 | 1; | ||
| 221 | __END__ |