When you aren't at Memory Alpha, click the down arrow on the minimap and select R&D Progress. The last tab is used to create schematics, the other tabs are used to create everything from personal armor to ship weapons. Aside from some consumables, you need a schematic, data samples (from scanning anomalies or the duty officer system), and usually unreplicatable materials (bought near the crafting areas on MA and Qo'nos for Dilithium).
No. You also do not need to have any data samples (the gathered crafting material from the anomalies) in your inventory. As long as you have them at least in your bank, you can still use/craft with them.
::WARNING:: This game is not intended for use as a source of self-esteem.