@SuppressWarnings("unchecked")
	Vector getChainInfo(int modelIndex, BitSet bs) {
		Model model = frame.mmset.getModel(modelIndex);
		int nChains = model.getChainCount();
		Vector infoChains = new Vector();
		for (int i = 0; i < nChains; i++) {
			Chain chain = model.getChain(i);
			Vector infoChain = new Vector();
			int nGroups = chain.getGroupCount();
			Hashtable arrayName = new Hashtable();
			for (int igroup = 0; igroup < nGroups; igroup++) {
				Group group = chain.getGroup(igroup);
				if (!bs.get(group.firstAtomIndex))
					continue;
				Hashtable infoGroup = new Hashtable();
				infoGroup.put("groupIndex", new Integer(igroup));
				infoGroup.put("groupID", new Short(group.getGroupID()));
				infoGroup.put("seqCode", group.getSeqcodeString());
				infoGroup.put("_apt1", new Integer(group.firstAtomIndex));
				infoGroup.put("_apt2", new Integer(group.lastAtomIndex));
				infoGroup.put("atomInfo1", getAtomInfo(group.firstAtomIndex));
				infoGroup.put("atomInfo2", getAtomInfo(group.lastAtomIndex));
				infoGroup.put("visibilityFlags", new Integer(group.shapeVisibilityFlags));
				infoChain.add(infoGroup);
			}
			if (!infoChain.isEmpty()) {
				arrayName.put("residues", infoChain);
				infoChains.add(arrayName);
			}
		}
		return infoChains;
	}