Calculate XRD pattern for 2D material

Hi
Is there to calculate xrd pattern of single or Double layer 2D material using pymatgen or any other software. I am working on Li intercalated Phosphorene. I want to calculate XRD for different Li concentration.

Thanks in Advance
Musa

Please post pymatgen questions on the pymatgen discourse: https://pymatgen.discourse.group/

Look at the XRDCalculator in pymatgen: https://github.com/materialsproject/pymatgen/blob/2a2e26e13063b8ea37ad83b6a22d4b26e2dfba5b/pymatgen/analysis/diffraction/xrd.py#L62