I'm not a lawyer, but I was always taught that because a digital format can be manipulated
that it can't count as fact without an un-broken chain of evidence. I forgot to add that part.
My Bad.
For many years after the PC scanners became common, the law still treated a FAXed signature as a legal signature, but they balked at saying a digitally copied signature on a PC was the same.
Now, with newer technology, the authenticity of a digital document and the signature can be verified. So, yes, a scan of a handwritten signature, a digitally signed document using an encrypted key, and a document signed using a third-party verification service like DocuSign are all legal in court now.
Even digital photos that were once viewed as easy to manipulate are admissible as long as a forensic expert can verify the contents of the document are unaltered from the original create date and time. With digital watermarks, that become quite easy now.
I used to save checksums of my important documents. That could be used in an instant to see if the document has been altered.