Adding animstategraph of a render entity to newly created entity. Playcanvas with photon

Hi, I am trying to create new model instances with Playcanvas and photon. I have succeeded in doing so
and the new model is created. I have scaled it to suit the size of the first model. However I do not know how to add the animations from the first model into the second.

const newPlayer = this.player.resource.instantiate();
    newPlayer.name = actor.actorNr;
    this.entity.addChild(newPlayer);
    newPlayer.setPosition(0, 0, 0);
    newPlayer.setLocalScale(0.005,0.005,0.005);

    var animStateGraphAsset = this.app.root.findByName("FPSPlayer").anim.stateGraphAsset;
    newPlayer.addComponent("anim", {stateGraphAsset: animStateGraphAsset});
    newPlayer.enabled = true;

Here is my code so far.
Please let me know.

Adding an animstatgraph asset is done a little differently for the anim component.

Please see the example here: https://developer.playcanvas.com/api/pc.AnimStateGraph.html