在值熊猫的特定序列之后提取一行?

时间:2018-10-13 09:22:53

标签: pandas extract data-mining

我有一个熊猫padaframe。我想提取遵循特定值序列的每个值。

var rootDoc = new XmlDocument();
rootDoc.LoadXml(xmlString); // the one from above

var adaptationSets = rootDoc.SelectNodes("//AdaptationSet");

if (adaptationSets.Count > 0)
    foreach (XmlNode adaptionSet in adaptationSets) // Loop through AdaptionSets
    {
        // Get the one Node in this AdaptionSet with the ContentComponent-Tag
        var contentComponent = adaptionSet.SelectSingleNode("./ContentComponent");

        if (contentComponent != null)
        {
            // parse attributes
        }

        // Get All Nodes in this AdaptionSet with the Representation-Tag
        var representations = adaptionSet.SelectNodes("./Representation");

        if (representations?.Count > 0)
            foreach (XmlNode representation in representations)
            {
                // parse attributes of XmlNode
            }
    }

在这种情况下,我想在新数据框中提取序列“ Cover”,“ House”,“ deg”之后的每个数字

有人可以帮助我吗? 干杯 米克

0 个答案:

没有答案