public int countPredicate(String predicate){
		int count=0;
		//Triples
		for (Triple t:triples){
			if (t.getPredicate().equals(predicate)){
				count++;
			}
		}
		//Triples in MSGs
		if (msgs!=null){
			for (MSG msg:msgs){
				for (Triple t:msg.getTriples()){
					if (t.getPredicate().equals(predicate)){
						count++;
					}
				}
			}
		}
		//Sub graphs
		for (NamedGraph subG:children){
			count+=subG.countPredicate(predicate);
		}
		return count;
	}