# AGC003A - Wanna go back home

from collections import Counter





def main():

    D = Counter(input().rstrip())

    flg = True

    if (

        (D["N"] != 0 and D["S"] == 0)

        or (D["N"] == 0 and D["S"] != 0)

        or (D["E"] != 0 and D["W"] == 0)

        or (D["E"] == 0 and D["W"] != 0)

    ):

        flg = False

    print(("Yes" if flg else "No"))





if __name__ == "__main__":

    main()
# AGC003A - Wanna go back home

def main():

    S = input().rstrip()

    flg = (("N" in S) ^ ("S" in S) ^ 1) & (("E" in S) ^ ("W" in S) ^ 1)

    print(("Yes" if flg else "No"))





if __name__ == "__main__":

    main()
# AGC003A - Wanna go back home
from collections import Counter


def main():
    D = Counter(input().rstrip())
    flg = True
    if (
        (D["N"] != 0 and D["S"] == 0)
        or (D["N"] == 0 and D["S"] != 0)
        or (D["E"] != 0 and D["W"] == 0)
        or (D["E"] == 0 and D["W"] != 0)
    ):
        flg = False
    print(("Yes" if flg else "No"))


if __name__ == "__main__":
    main()

# AGC003A - Wanna go back home
def main():
    S = input().rstrip()
    flg = (("N" in S) ^ ("S" in S) ^ 1) & (("E" in S) ^ ("W" in S) ^ 1)
    print(("Yes" if flg else "No"))


if __name__ == "__main__":
    main()

-from collections import Counter - - -    D = Counter(input().rstrip()) -    flg = True -    if ( -        (D["N"] != 0 and D["S"] == 0) -        or (D["N"] == 0 and D["S"] != 0) -        or (D["E"] != 0 and D["W"] == 0) -        or (D["E"] == 0 and D["W"] != 0) -    ): -        flg = False +    S = input().rstrip() +    flg = (("N" in S) ^ ("S" in S) ^ 1) & (("E" in S) ^ ("W" in S) ^ 1)