Replacing Family Instances with new Family

Thank you Jacob,
I found this python code on the forum (https://forum.dynamobim.com/t/familyinstance-bypoint-overwrites/10258/13),

import clr

clr.AddReference("RevitServices")
clr.AddReference("RevitNodes")
import RevitServices
from RevitServices.Persistence import DocumentManager
from RevitServices.Transactions import TransactionManager
doc =  DocumentManager.Instance.CurrentDBDocument

import Revit
clr.ImportExtensions(Revit.Elements)
clr.ImportExtensions(Revit.GeometryConversion)

clr.AddReference("RevitAPI")
from Autodesk.Revit.DB import *


def ptslist(obj1):
    if hasattr(obj1,"__iter__"): return obj1
    else: return [obj1]

famType = UnwrapElement(IN[0])
pts = ptslist(IN[1])
lvl = UnwrapElement(IN[2])


elems = []

for pt in pts:
    TransactionManager.Instance.EnsureInTransaction(doc)
    elems.append(doc.Create.NewFamilyInstance(pt.ToRevitType(True), famType, lvl, Structure.StructuralType.NonStructural))
    TransactionManager.Instance.TransactionTaskDone()
	
OUT = elems

which allows to insert a family into a view…

I wish I could use it with a list of several views, but I do not know how to modify the code
Thank you, your help would be valuable to me