For discovering Amsterdam by public transport and museum visits, March, April, May, September and October are usually the most pleasant months. The weather is often mild enough in that period to spend time outside between stops, while the city stays lively without feeling at its busiest straight away. That makes it easier to travel between museums by tram, metro or bus and still have time for a terrace stop or a short walk.
In spring, you often get fresh, clear days that suit a city break well. In autumn, the city settles back into its rhythm, with enough daylight for a full day out. Outside these months, it can still work well, but the experience does change. In summer, the crowds ask for more patience and planning. In winter, the visit more often becomes about staying indoors and moving smartly between public transport stops, museums and food and drink places.