Python/Javascript parsing - having trouble with a particular string -


trying parse table under "wolfsburg" this site can't seem figure out data formatted in way. novice eyes there doesn't seem sort of logical structure make able converted else json or xml , parsed way.

the relevant part of script follows , info i'm interested in stats each individual player :

<script type="text/javascript">      var matchstats = [[33,'wolfsburg',6.27928571428571,[[['blocked_scoring_att',[3]],['accurate_pass',[139]],['att_miss_left',[1]],['won_contest',[7]],['total_scoring_att',[9]],['total_throws',[26]],['aerial_won',[33]],['total_pass',[263]],['att_miss_high_left',[1]],['att_miss_right',[1]],['total_tackle',[23]],['total_offside',[7]],['shot_off_target',[6]],['aerial_lost',[29]],['fk_foul_lost',[7]],['won_corners',[3]],['possession_percentage',[29.4]],['att_miss_high',[3]]]],[[73797,'koen casteels',5.71,[[['accurate_pass',[8]],['touches',[35]],['saves',[2]],['aerial_won',[1]],['total_pass',[29]],['formation_place',[1]]]],1,'gk',1,0,0,'gk',25,197,86]  ,[320002,'felix uduokhai',6.52,[[['accurate_pass',[19]],['touches',[51]],['won_contest',[1]],['aerial_won',[2]],['total_pass',[33]],['total_tackle',[4]],['aerial_lost',[1]],['formation_place',[6]]]],2,'dc',17,0,0,'d(c)',20,188,78]  ,[130899,'yannick gerhardt',6.64,[[['accurate_pass',[18]],['touches',[65]],['total_scoring_att',[1]],['aerial_won',[7]],['total_pass',[32]],['total_tackle',[3]],['aerial_lost',[2]],['formation_place',[3]]]],2,'dl',13,0,0,'d(l),m(cl)',23,184,81]  ,[100591,'robin knoche',5.92,[[['accurate_pass',[12]],['touches',[41]],['aerial_won',[2]],['total_pass',[29]],['aerial_lost',[2]],['formation_place',[5]]]],2,'dc',31,0,0,'d(c)',25,190,77]  ,[16243,'paul verhaegh',6.41,[[['accurate_pass',[8]],['touches',[44]],['aerial_won',[1]],['total_pass',[20]],['total_tackle',[2]],['aerial_lost',[1]],['formation_place',[2]]]],2,'dr',3,0,0,'d(r),m(r)',34,178,74]  ,[133959,'riechedly bazoer',6.13,[[['blocked_scoring_att',[1]],['accurate_pass',[9]],['touches',[25]],['won_contest',[2]],['total_scoring_att',[1]],['total_pass',[15]],['aerial_lost',[2]],['fouls',[3]],['formation_place',[8]]]],3,'dmc',6,1,59,'dmc',20,184,81]  ,[35199,'ignacio camacho',7.21,[[['accurate_pass',[19]],['touches',[57]],['won_contest',[1]],['aerial_won',[4]],['total_pass',[34]],['total_tackle',[6]],['fouls',[1]],['formation_place',[4]]]],3,'dmc',4,0,0,'m(c)',27,182,75]  ,[44142,'daniel didavi',6.38,[[['blocked_scoring_att',[1]],['accurate_pass',[9]],['touches',[35]],['total_scoring_att',[2]],['aerial_won',[3]],['total_pass',[16]],['total_tackle',[2]],['aerial_lost',[3]],['formation_place',[10]]]],3,'amc',11,1,69,'am(cr)',27,180,78]  ,[21988,'jakub blaszczykowski',6.23,[[['accurate_pass',[4]],['touches',[15]],['won_contest',[1]],['aerial_won',[2]],['total_pass',[7]],['total_tackle',[2]],['aerial_lost',[4]],['formation_place',[7]]]],3,'amr',16,1,42,'d(r),m(cr)',31,176,77]  ,[298512,'kaylen hinds',5.94,[[['accurate_pass',[9]],['touches',[24]],['aerial_won',[2]],['total_pass',[13]],['total_tackle',[1]],['aerial_lost',[4]],['formation_place',[11]]]],3,'aml',32,0,0,'forward',19,180,]  ,[6255,'mario gomez',6.19,[[['blocked_scoring_att',[1]],['accurate_pass',[8]],['touches',[23]],['total_scoring_att',[4]],['aerial_won',[6]],['total_pass',[14]],['aerial_lost',[9]],['fouls',[1]],['formation_place',[9]]]],4,'fw',33,0,0,'fw',32,189,88]  ,[298510,'victor osimhen',0,[[['formation_place',[0]]]],5,'sub',18,0,0,'forward',18,185,78]  ,[108919,'maximilian arnold',6.31,[[['accurate_pass',[5]],['touches',[18]],['won_contest',[2]],['total_pass',[7]],['total_tackle',[2]],['fouls',[2]],['formation_place',[0]]]],5,'sub',27,2,69,'m(cr)',23,184,74]  ,[344071,'landry dimata',6.05,[[['accurate_pass',[9]],['touches',[19]],['aerial_won',[1]],['total_pass',[10]],['aerial_lost',[1]],['formation_place',[0]]]],5,'sub',9,2,42,'forward',20,185,79]  ,[93307,'paul-georges ntep',0,[[['formation_place',[0]]]],5,'sub',7,0,0,'am(l),fw',25,180,82]  ,[51428,'max grün',0,[[['formation_place',[0]]]],5,'sub',20,0,0,'gk',30,190,86]  ,[70105,'josuha guilavogui',6.27,[[['accurate_pass',[2]],['touches',[10]],['total_scoring_att',[1]],['aerial_won',[2]],['total_pass',[4]],['total_tackle',[1]],['formation_place',[0]]]],5,'sub',23,2,59,'m(c)',26,187,77]  ,[104919,'yunus malli',0,[[['formation_place',[0]]]],5,'sub',10,0,0,'am(cl),fw',25,179,70]  ],['4231',[[5,1]  ,[8,3]  ,[2,3]  ,[4,5]  ,[6,3]  ,[4,3]  ,[7,7]  ,[6,5]  ,[5,9]  ,[5,7]  ,[3,7]  ]]  ]  ,[44,'borussia dortmund',7.295,[[['blocked_scoring_att',[3]],['att_goal_low_left',[2]],['accurate_pass',[520]],['att_miss_left',[4]],['won_contest',[7]],['ontarget_scoring_att',[5]],['total_scoring_att',[13]],['total_throws',[33]],['aerial_won',[29]],['total_pass',[649]],['goals',[3]],['total_tackle',[20]],['att_goal_high_right',[1]],['att_sv_low_centre',[1]],['shot_off_target',[5]],['aerial_lost',[33]],['att_sv_low_right',[1]],['fk_foul_lost',[15]],['won_corners',[5]],['possession_percentage',[70.6]],['att_miss_high',[1]]]],[[63936,'roman bürki',6.6,[[['accurate_pass',[33]],['touches',[48]],['total_pass',[44]],['formation_place',[1]]]],1,'gk',38,0,0,'gk',26,187,85]  ,[22210,'sokratis',7.36,[[['accurate_pass',[89]],['touches',[113]],['aerial_won',[5]],['total_pass',[106]],['total_tackle',[1]],['aerial_lost',[5]],['fouls',[1]],['formation_place',[5]]]],2,'dc',25,0,0,'d(cr)',29,186,85]  ,[11090,'lukasz piszczek',7.16,[[['accurate_pass',[60]],['touches',[97]],['aerial_won',[3]],['total_pass',[72]],['total_tackle',[2]],['aerial_lost',[3]],['fouls',[2]],['formation_place',[2]]]],2,'dr',26,0,0,'d(cr),m(r)',32,184,79]  ,[83686,'marc bartra',8.93,[[['accurate_pass',[74]],['touches',[115]],['total_scoring_att',[1]],['aerial_won',[10]],['total_pass',[100]],['goals',[1]],['total_tackle',[1]],['fouls',[1]],['formation_place',[6]],['man_of_the_match',[1]]]],2,'dc',5,0,0,'d(c)',26,184,73]  ,[342548,'dan-axel zagadou',7.87,[[['accurate_pass',[40]],['touches',[83]],['won_contest',[2]],['total_scoring_att',[1]],['aerial_won',[6]],['total_pass',[50]],['total_tackle',[3]],['aerial_lost',[1]],['fouls',[2]],['formation_place',[3]]]],2,'dl',2,1,78,'defender',18,196,90]  ,[80382,'mario götze',7.59,[[['accurate_pass',[33]],['touches',[50]],['won_contest',[1]],['total_scoring_att',[2]],['goal_assist',[1]],['total_pass',[41]],['total_tackle',[2]],['formation_place',[8]]]],3,'mc',10,1,61,'m(clr),fw',25,176,75]  ,[13423,'gonzalo castro',7.42,[[['accurate_pass',[52]],['touches',[74]],['total_scoring_att',[2]],['goal_assist',[1]],['total_pass',[60]],['total_tackle',[2]],['aerial_lost',[2]],['formation_place',[7]]]],3,'mc',27,0,0,'m(cr)',30,172,74]  ,[14176,'nuri sahin',7.64,[[['accurate_pass',[51]],['touches',[81]],['aerial_won',[3]],['total_pass',[65]],['total_tackle',[4]],['aerial_lost',[5]],['fouls',[4]],['formation_place',[4]]]],3,'mc',8,0,0,'m(c)',29,180,73]  ,[44120,'pierre-emerick aubameyang',7.52,[[['blocked_scoring_att',[2]],['accurate_pass',[26]],['touches',[52]],['total_scoring_att',[4]],['total_pass',[35]],['goals',[1]],['total_tackle',[1]],['aerial_lost',[4]],['fouls',[3]],['formation_place',[9]]]],4,'fw',17,0,0,'m(lr),fw',28,187,80]  ,[302692,'christian pulisic',8.52,[[['accurate_pass',[21]],['touches',[49]],['won_contest',[2]],['total_scoring_att',[1]],['goal_assist',[1]],['total_pass',[28]],['goals',[1]],['total_tackle',[1]],['aerial_lost',[8]],['formation_place',[10]]]],4,'fwr',22,1,86,'m(clr)',18,172,69]  ,[145267,'maximilian philipp',7.13,[[['blocked_scoring_att',[1]],['accurate_pass',[19]],['touches',[34]],['total_scoring_att',[2]],['aerial_won',[2]],['total_pass',[24]],['total_tackle',[2]],['aerial_lost',[3]],['fouls',[1]],['formation_place',[11]]]],4,'fwl',20,0,0,'am(lr),fw',23,184,77]  ,[25482,'neven subotic',0,[[['formation_place',[0]]]],5,'sub',4,0,0,'d(c)',28,191,83]  ,[43589,'Ömer toprak',0,[[['formation_place',[0]]]],5,'sub',36,0,0,'d(c)',28,186,83]  ,[42862,'shinji kagawa',5.85,[[['accurate_pass',[2]],['touches',[4]],['total_pass',[3]],['fouls',[1]],['formation_place',[0]]]],5,'sub',23,2,86,'am(cl)',28,175,68]  ,[135092,'mahmoud dahoud',6.39,[[['accurate_pass',[14]],['touches',[20]],['won_contest',[2]],['total_pass',[15]],['total_tackle',[1]],['aerial_lost',[2]],['formation_place',[0]]]],5,'sub',19,2,61,'m(c)',21,177,69]  ,[312843,'felix passlack',6.15,[[['accurate_pass',[6]],['touches',[10]],['total_pass',[6]],['formation_place',[0]]]],5,'sub',30,2,78,'midfielder',19,170,74]  ,[299254,'alexander isak',0,[[['formation_place',[0]]]],5,'sub',14,0,0,'fw',17,190,74]  ,[5490,'roman weidenfeller',0,[[['formation_place',[0]]]],5,'sub',1,0,0,'gk',37,190,90]  ],['433',[[5,1]  ,[2,3]  ,[8,3]  ,[5,6]  ,[4,3]  ,[6,3]  ,[3,6]  ,[7,6]  ,[5,9]  ,[3,9]  ,[7,9]  ]]  ]  ]  ], 0];                var liveteamstatsinfoconfig = {          view: {              renderto: 'match-report-team-statistics',              width: 250,              labelwidth: 100          },          model: {              instancetype: liveteamstatssummaryinfomodel,              labelgroups: [              {                  start: 0,                  end: 5,                  clazz: "no-top-margin",                  labelwidth: 120,                  statvaluewidth: 60,                  hidebars: true                },              {                  start: 6,                  end: 6,                  title: 'possession',                  labelwidth: 0              }              ],              labels: [              {                  type: 'value',                  displayvalue: 'shots'                  },                  {                      type: 'value',                      displayvalue: 'shots on target'                  },                  {                      type: 'percentage',                      displayvalue: 'pass success %'                  },                  {                      type: 'percentage',                      displayvalue: 'aerial duel success'                  },                  {                      type: 'value',                      displayvalue: 'dribbles won'                  },                  {                      type: 'value',                      displayvalue: 'tackles'                  },                  {                      type: 'percentage',                      displayvalue: ''                  }                  ]          }      };            var liveteamstatsinfo = new ws.stats.info(liveteamstatsinfoconfig);                liveteamstatsinfo.load({ home: matchstats[0][2][0], away: matchstats[0][2][1] });            $(document).bind('match-live-player-stats-' + 1201836 + '-updated', function(options, data) {              liveteamstatsinfo.load({ home: data[1][0], away: data[1][1] });          });  </script>


Comments

Popular posts from this blog

angular - Ionic slides - dynamically add slides before and after -

minify - Minimizing css files -

Add a dynamic header in angular 2 http provider -