実際にはブラックベルト、それが私がそれを解決した方法のほとんどですが、コピーしたレイアウトを新しいレイアウトに追加するときにまだエラーが発生しました。その理由は、コピーしたいレイアウトにまだ親があったためです。ここに完全なソリューションがあります(layoutRootはres/layoutにあるxmlレイアウトで、myLinearLayoutはファイルlayoutRoot内のLinearLayoutです。layoutToPlaceCopiedLayoutは、コピーしたレイアウトを配置したいレイアウト内のLinearLayoutです)。
LinearLayout newLayout = (LinearLayout)findViewById(R.id.layoutToPlaceCopiedLayout)
LayoutInflater inflater = LayoutInflater.from(this);
LinearLayout layoutRootCopy = (LinearLayout)inflatefrom(R.layout.layoutRoot);
LinearLayout layoutCopy = (LinearLayout)layoutRootCopy.findViewById(R.id.myLinearLayout);
ViewGroup parent = (ViewGroup)layoutCopy.getParent();
int index = parent.indexOfChild(layoutCopy);
parent.removeView(layoutCopy);
newLayout.addView(layoutCopy, index);